What happens when a main method is declared as private?
Answer Posted / harsha
When a method is declared as private, the program compiles
properly but it will give runtime error ?Main method not
public"
Is This Answer Correct ? | 111 Yes | 8 No |
Post New Answer View All Answers
What should I import for arraylist in java?
What is size of int in java?
What does percent mean in java?
Why hashset is used in java?
What are different types of expressions?
What is a heavyweight component?
What is the purpose of garbage collection in java? When is it used?
How to perform linear search in java?
Give me example of derived data types.
What is the difference between stored procedure & function?
Why does java not allow multiple public classes in a java file ?
How can we make sure main() is the last thread to finish in java program?
What is java command?
How do you know if a value is nan?
Is class is a data type?