Is there is any error if you have multiple main methods in
the same class?
Answer Posted / srikanth
No, there is no error if we have multiple main methods
in the same class.
because, while compiling we only specify one main method
name so, the JVM compiles it by taking the main method which
is specified by us while compiling.
| Is This Answer Correct ? | 3 Yes | 23 No |
Post New Answer View All Answers
Can a boolean be null java?
What is a loop java?
What is difference between array and arraylist in java?
What is arraylist e in java?
Explain about the select method with an example?
What are predicates in java 8?
What is a void method?
What is loop in java?
Does java list allow null?
Why are lists ordered in java?
What is use of arraylist in java?
How would you format a date in java? I.e. In the ddmmyyy format?
What is == and === in javascript?
Why map is used in java?
What does null mean in java?