What happens when a main method is declared as private?

Answer Posted / r.jainrocks@gmail.com

Byte that have main() implementation can become starting
point of program .

if a program have no main()

i.e.
public static void main(String[] args)

properly it can't become starting point in application
it can be use through other program which capable to become
starting point.

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is exception in java?

755


what is meant by HQL?

840


Explain the importance of finally over return statement?

821


What is a local, member and a class variable?

782


What is the benefit of abstract class?

712


What is java oops?

777


What is the final keyword in java?

1025


What are the different types of sorting in java?

739


What are bind parameters?

765


How many functional interfaces does java 8 have?

807


Can we have any code between try and finally blocks?

774


Why declare Main() inside the class in java ?

803


What is the difference between state-based unit testing and interaction-based unit testing?

721


Describe the Big-O Notation.

810


How many bits is a boolean?

818