Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


why we use main in java?

Answers were Sorted based on User's Feedback



why we use main in java? ..

Answer / amit

look guys,we use main() method inside java cause whenever we
compile .java file then jvm call classname.main() first
without make any object.main method must be public and static
cause public for wide accessing and jvm call main() without
creating any object its only possible when main() is static
method.and all the argument taken by main in form of string
thats why we write as.......
public static void main(String args[])
it canbe
public final static void main(String args[])

Is This Answer Correct ?    24 Yes 0 No

why we use main in java? ..

Answer / poojadayal1989

we are using main in java bcoz its entry point of all
program..bcoz of static it can execute first.

Is This Answer Correct ?    6 Yes 2 No

why we use main in java? ..

Answer / suribabu

the program execution starts from the main()method.

Is This Answer Correct ?    2 Yes 0 No

why we use main in java? ..

Answer / sri

application begin execution by calling main() method of
that class

Is This Answer Correct ?    3 Yes 8 No

Post New Answer

More Advanced Java Interview Questions

what is stringBuffer and StringBuilder?

3 Answers  


difference. between List and Set?

2 Answers   Campus Interaction, HCL, Infotech,


What method MUST be implemented by all threads?

1 Answers  


What will happens, when a thread cannot acquire a lock on an object?

2 Answers  


What value does read() return when it has reached the end of a file?

0 Answers  


what is JTS?

1 Answers  


Give me simple example of hibernate caching and explain the details of caching????? thanks in adv.

1 Answers  


How would you reatach detached objects to a session when the same object has already been loaded into the session?

0 Answers  


What is the argument type of a programs main() method?

0 Answers  


How can a dead thread be restarted?

1 Answers   IBM, Wipro,


How to add new JTabbed pane?

1 Answers  


Which class is the immediate superclass of the menucomponent class?

0 Answers  


Categories