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...

In Java why we write public static void main(String args[])
why not main()?

Answer Posted / sumalatha

yes in every progrm in jave the main is static.because when
the program will start ,thit means runnig then the main is
also one method it was called first that means without
instans creations the main is called.thet is the reason we
are put as main is static method(static is used for without
instance creat u call it).void means it does not reaturn
any value

Is This Answer Correct ?    148 Yes 43 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is map ordered in java?

952


What is the difference between object oriented programming language and object based programming language?

1022


Can we call virtual funciton in a constructor ?

2208


What is the multi-catch block in java?

1043


what are synchronized methods and synchronized statements? : Java thread

1001


Write a program to reverse array in place?

1073


What are static methods?

1055


Can we call a non-static method from inside a static method?

1000


Garbage collection in java?

1025


What is the default size of load factor in hashing based collection?

1052


What are facelets templates?

1036


Explain importance of finally block in java?

1041


What are the loops in java?

989


How do you change an int to a string?

1014


What is string args [] in java?

1038