Why do we use public static with the main function in Java?
Answer Posted / saikat chowdhury
'public' keyword is an access specifier.It means you can access anywhere of the program using this specifier.When we use in the main function it can be access outside of the(class, package,subclass.'Static' also a keyword.When we use this in the main function that means you do not need to create the object of static.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Difference between notify() method and notifyall() method in java?
What are the two categories of data types in the java programming language?
How to create a base64 decoder in java8?
Why are global variables used?
How to access arraylist elements in java?
Why convert an applet to an application?
os is developed in c no java is more secured then c na why dont the os developed is developed using java
what is the significance of listiterator in java?
What is autoboxing and unboxing?
What is a jagged array in java?
What is an immutable object? How do you create one in java?
When we should use serialization?
Explain hashset and its features?
What is the null?
Why java is not 100% object-oriented?