Why do we use public static with the main function in Java?
Answer Posted / rameshreddy.k
As we know public means we can access the method from
anywhere. in a java we want call method by using class
object. But main() is also method .that main() is there one
class but jVM execute program trough main() method with out
creating object main() method call thats way we use public
static the main function
thanks& regargs
RAMESH
| Is This Answer Correct ? | 4 Yes | 4 No |
Post New Answer View All Answers
What are generic methods?
What is a java developer salary?
What happens if constructor is private?
What is equlas() and hashcode() contract in java? Where does it used?
Why unicode is important?
How do you reverse a word in java?
how to deploy tomcatserver to weblogic server? write d following steps?
What do you mean by access modifier?
What carriage return means?
What does it mean to flush a file?
What is the difference between Grid and Gridbaglayout?
Describe 2 different ways to concatenate two strings.
how to split string in java?
What is the purpose of interface?
What is private static in java?