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

Is void a wrapper class?

541


What is void keyword?

684


What is the integer of 16?

543


Explain polymorphism citing an example.

601


Explain restrictions on using enum?

642






What is the difference between numeric and integer?

517


Which java collection does not allow null?

721


What programs use java?

478


Is an object null?

565


Explain the use of shift operator in java. Can you give some examples?

549


What is the tradeoff between using an unordered array versus an ordered array?

674


Explain about exception propagation?

589


What is meant by null and void?

549


What is bigger kb or mb?

594


Explain the scope or life time of class variables or static variables?

525