java - Where is main stored & is main a keyword? I do know that main() is a method but I am asking about "main" -


i know main() method used in c/c++ & java since main() user defined (as code inside main() defined user, can't predefined method) & in c/c++ main not stored in header file, located compiler first searches in program? , main keyword or else? heard somewhere attribute used keyword not sure. can please me this? (i know in case of both java & c/c++)

main not predefined, is predeclared. in c, code linked against small runtime library constitutes true starting point of program. small library minimal amount of stack setup, calls function called main--it's hardcoded so. code runs because supply definition of main.

the java runtime similar: bootstrap code in virtual machine invoke main method of whatever class provided input.


Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -