Why do we use public static with the main function in Java?
Answer Posted / deepak divvela
In the main function generally we are using
public static void main(String args[])
that means public is used for call method without being the
member of the class.
and static is used for to call method directly with no need
of the object creation.
Is This Answer Correct ? | 3 Yes | 7 No |
Post New Answer View All Answers
What methods are used to get and set the text label displayed by a button object?
Does apple use java?
Explain the JDB in depth & command line.
Can I declare a class as private?
Why is a string immutable?
What is an inner class in java?
What is java and why do we need it? Explain
What are the data types supported by java? What is autoboxing and unboxing?
What is a concrete classes? Is Java object class is concrete class?
What is a nullable field?
What is off heap memory?
Does sprintf allocate memory?
Can subclass overriding method declare an exception if parent class method doesn't throw an exception?
Explain working of call by reference function invoking.
write a program that list all permutations of ABCDEF in which A appears before B?