September 16, 2008 at 11:37 AM
In java no need of main method u rember this thing first.
when u create a class it follow certain principle.
means it conatin mostly variable and methods. ie declaration section and method body (defination).
so in declaration section you can,t acces any method of other class or else self class. it happens on in a defination section. in declaration u create object of any class and any kind of varaible.
September 16, 2008 at 12:18 PM
If you comment the main method and it gives error on compile.
because method require to create the object.Without any method declaration gives error.
For beginner in java to visit...http://www.roseindia.net/java/beginners/