Java Interview Questions
When a method is declared as private, the program compiles properly but it will give runtime error Main method not “public„.