can we overload main method?

Answer Posted / shrirang & chetak

yes , we can overlode main method but we can not override
main method

example :
class a
{
public void main()
{
System.out.println("0.00000000");
}

public static void main(String ar[])
{
a A=new a();
A.main();
}
}

Is This Answer Correct ?    13 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is void class in java?

528


What is e in java?

541


Is java se open source?

571


Write java program to reverse string without using api?

554


Is char a method in java?

516






Why convert an applet to an application?

616


What is the method to expand and collapse nodes in a jtree?

610


if u open login & logout ,how can udisplay the timelogin & logout members ?

1755


Is arraylist dynamic in java?

519


What is multi level inheritance in java?

558


How do you access command-line arguments within the code?

573


What is java full form?

531


What is meant by call by reference?

511


Explain enumeration in java?

568


What is the difference between class forname and new?

552