What happens when a main method is declared as private?
Answer Posted / srinivasa
JVM is also a program. If main() is declared as privateit
is not available outside of that class . So JVM through the
exception.
| Is This Answer Correct ? | 15 Yes | 5 No |
Post New Answer View All Answers
What is singleton service?
Does list maintain insertion order java?
What is the file extension for java?
How is java created?
Implement 2 stacks with just 1 array. The stack routines must not indicate overflow unless every slot in array is used.
What is gui programming?
What is the right data type to represent a price in java?
what is the difference between yielding and sleeping? : Java thread
What is the difference between member variables initialization and assignment in a constructor?
What is the difference between I ++ and ++ I in java?
What is the order of arraylist in java?
a thread is runnable, how does that work? : Java thread
In Java list the methods that can be overridden?
How can we use primitive data types as objects?
What do you understand by weak reference?