why applet doesn't have main? isn't possible a program with
out main?

Answer Posted / nagaraju gurram

first of all we can write a program without main method .
and in case if applets they are intended for web development so the applets need to be alive during the navigation . but main will exit after completion of the execution and terminates the object .and main thing is main is a starting point of a program and there is no controlling on main but in case of web page we have to control the object during the navigation.that is the reason where an object should contain a life and through life cycle methods defined.............

Than Q

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why stringbuilder is not thread safe in java?

782


What is a newline character in java?

775


What is data type modifier?

705


Can we execute a program without main?

732


What is dot operator?

777


How do you input a string in java?

737


What is the new line character?

815


What are inbuilt functions in java?

786


Can we have multiple public classes in a java source file?

771


What are the features of junit?

811


Why there is no call by reference in java?

686


What are the characteristics of java?

723


What is the function of compareto in java?

792


What is lossy conversion in java?

802


Explain reverse a linked list iterative solution in java?

698