Can the main method be declared final?



Can the main method be declared final?..

Answer / Narendra Pratap Gangwar

Yes, the main method can be declared as final in Java. By default, it is not final. Declaring the main method as final prevents other methods from overriding it in subclasses.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Java Related AllOther Interview Questions

Are the actual permissions for the application defined at run-time or compile-time? : java security

1 Answers  


Is java secure? : java security

1 Answers  


Explain about the Physical Data Model?

1 Answers   HCL,


Where is singleton design pattern used in java?

1 Answers  


What is java ioc?

1 Answers  


Do I need jdk or jre?

1 Answers  


How do I open the java console in windows 10?

1 Answers  


How do I install java re?

1 Answers  


What is the resourcebundle class?

0 Answers  


How can I check single byte, double byte of character in JTextField?(eg. japan unicode and English unicode)

0 Answers  


What is jdk for netbeans ide?

1 Answers  


What is flatmap in rxjs?

1 Answers  


Categories