Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

What happens when a main method is declared as private?

Answer Posted / amit kumar chaubey

If the main function is made private...it will compile
Sucessfully...and at the time of execution...it will
execute successfully...but desired result will not be
obtained. After execution..folowin message will be printed:
Main method not public.

Is This Answer Correct ?    25 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between array and array list in java?

232


What is multiple inheritance? Is it supported by java?

203


What is a parameter example?

185


Do you need to import math in java?

187


Which eclipse is best for java?

178






Is java same as core java?

206


Is linkedlist thread safe in java?

162


Why we cannot override static method?

199


What are the 6 boolean operators?

173


What is the difference between a choice and a list?

186


How to find the given number is a prime number or not by getting input from the user

217


What is a qualifier in a sentence?

191


How to make a read-only class in java?

217


What is a conditional statement explain with example?

177


What restrictions are placed on method overloading in java programming?

195