What happens when a main method is declared as private?

Answer Posted / ashish

it compile easily... but it will give an error at the time
of execution .....

Is This Answer Correct ?    12 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When do we need to use internal iteration? When do we need to use external iteration?

591


Why do people says “java is robust”?

540


What class allows you to read objects directly from a stream in java programming?

499


What is treemap in java?

536


How is Object Oriented Programming different from Procedure Oriented Programming?

577






can java object be locked down for exclusive use by a given thread? : Java thread

516


Why hashmap is used in java?

536


What is final variable?

486


Can an integer be a string?

501


How many types of equations are there?

526


Is integer passed by reference in java?

549


List some features of the abstract class.

578


Where and how can you use a private constructor?

522


Where are global variables stored?

500


Can we overload the constructors?

549