I get an exception if I remove the static modifier from main?
Answer / Amitesh Srivastava
Yes, removing the static modifier from the main method in Java will result in a compile-time error. The main method must be declared as static so that it can be called by the JVM.
| Is This Answer Correct ? | 0 Yes | 0 No |
Is jdk an ide?
Why oracle type 4 driver is named as oracle thin driver?
What is meant by annotation in java?
What is gui in java with examples?
What is the locale class?
What is data encapsulation?
Can we use lambda without functional interface?
What are jpa repositories?
What do you mean by exception handling?
What is jpa project?
What are the types of cookies in java?
What is phantom memory?