In Java, what are public static void main string args?
Answer Posted / glibwaresoftsolutions
The access modifier "public" is used to define who has access to this method. Any class can use this method as well.
• The Java keyword "static" indicates when something is class-based. Java makes main() static so that it can be accessed without requiring the creation of a class instance. Since the JVM calls main() before creating any objects, the compiler will raise an error if main is not set to static. It can only use the class to directly call static methods.
• The method that defines the method's return type is called Void. There is no value returned by that procedure.
• Main is the name of the method that the JVM looks for when an application (with a certain signature only) starts. It is
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why java is called not pure object oriented language?
What are abstract methods in java?
What is the use of :: in java?
What string is utf8?
If system.exit (0); is written at the end of the try block, will the finally block still execute?
What is a package in java? List down various advantages of packages.
Explain the term virtual machine?
How do I print a “?
Tell us something about set interface.
What are different data structures in java?
What is string in java is it a data type?
Is java still necessary?
Is static variable stored in heap?
Can we catch more than one exception in single catch block?
What are different types of expressions?