in a console we r giving java <class name> if r pressing
enter where it'll goes
Answers were Sorted based on User's Feedback
Answer / srujan jack
it transfers the class name to JVM then the JVM calls main() method using class name.
there fore the main() method must be declared with public & static.....
| Is This Answer Correct ? | 2 Yes | 0 No |
what is thread? What are the high-level thread states? Or what are the states associated in the thread? : Java thread
What is consumer in java?
Why is stringbuffer not immutable?
How can the checkbox class be used to create a radio button?
What is the maximum size of array in java?
What is a void in java?
Can you explain the Java thread lifecycle?
What is equlas() and hashcode() contract in java? Where does it used?
What happens when the main() isn't declared as static?
why java main method is given as static method?
What is the difference between an interface and an abstract class?
What is a line separator in java?