In Java why we write public static void main(String args[])
why not main()?
Answer Posted / ravi
static because once the class is loaded the main() will be
invoked first.
void because main()is not returning any value.
| Is This Answer Correct ? | 228 Yes | 99 No |
Post New Answer View All Answers
Differece between class and generic class?
why doesn't java run on all platforms?
What do you mean by boolean?
How can we access some class in another class in java?
How does thread synchronization occurs inside a monitor?
Class c implements interface I containing method m1 and m2 declarations. Class c has provided implementation for method m2. Can I create an object of class c?
What exactly is a .class file?
How does arraylist size increase in java?
How the metacharacters are different from the ordinary characters?
What is bubble sort in java?
Is array synchronized in java?
How many return statement are allowed in a function?
What is method reference in java?
What is the size of int?
What's the default access specifier for variables and methods of a class?