Is there is any error if you have multiple main methods in
the same class?
Answer Posted / nisha
The compilation error, if you have multiple main
methods in the same class.
Error like :java.lang.ExceptionInInitializerError
Caused by: java.lang.RuntimeException: Uncompilable source
code - main(java.lang.String[]) is already defined
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Is arraylist zero based?
What are selection structures?
What is the difference between a vector & an array list?
What is connection class in java?
What is a class variable?
What is the most important feature of java? What is an interface?
What is a method signature java?
Explain java thread life cycle.
What is the protected method modifier?
What is the difference between I ++ and ++ I in java?
What is the benefit of inner classes in java?
What are the advantages of autoboxing?
What are bind parameters?
Write a program to calculate factorial in java?
What is regex used for?