JAVA INTERVIEW QUESTIONS

 Important questions 

1 It is possible to compile a java program without declaration the main method?

YES it possible 

2 It is possible to run a java program without a declaration main method?

NO

3 It is possible in java to declare the main method in multiple classes in some programs?

Yes 

4 Is It possible in java to declare multiple main methods in the same class in java?

yes, it is possible when JVM is call string then remains is call in main value.

5 Is it possible to save the java program with any name?

it will be compiled with the name of the same data and run with the name of the main class.

6 It is possible to save the java program without any name?

yes 

7 Is it possible to call the main method by the program?

yes 

Post a Comment

0 Comments