In Java why we write public static void main(String args[])
why not main()?
Answer Posted / sumalatha
yes in every progrm in jave the main is static.because when
the program will start ,thit means runnig then the main is
also one method it was called first that means without
instans creations the main is called.thet is the reason we
are put as main is static method(static is used for without
instance creat u call it).void means it does not reaturn
any value
| Is This Answer Correct ? | 148 Yes | 43 No |
Post New Answer View All Answers
Is map ordered in java?
What is the difference between object oriented programming language and object based programming language?
Can we call virtual funciton in a constructor ?
What is the multi-catch block in java?
what are synchronized methods and synchronized statements? : Java thread
Write a program to reverse array in place?
What are static methods?
Can we call a non-static method from inside a static method?
Garbage collection in java?
What is the default size of load factor in hashing based collection?
What are facelets templates?
Explain importance of finally block in java?
What are the loops in java?
How do you change an int to a string?
What is string args [] in java?