Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Non -static main method in java class

807580Nov 6 2009 — edited Nov 6 2009
Hi GM to all

My question is "Does non static main method exist in java class?"

Ex

class Pro
{
public void main(String args[])
{
Pro p=new Pro();
system.out.println("Hello World");
p.main();
}
}
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 4 2009
Added on Nov 6 2009
24 comments
1,758 views