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

What is an example of a conditional statement?

1003


Define max and min heap, also the search time of heap.

995


What is visibility mode?

916


Tell us something about an iterator.

909


how to create multithreaded program? Explain different ways of using thread? : Java thread

922


When a lot of changes are required in data, which one should be a preference to be used? String or stringbuffer?

1207


How to add menushortcut to menu item?

973


What is anti pattern in java?

919


What java is used for?

1035


Does chrome use java?

927


Is it necessary for the port addresses to be unique? Explain with reason.

983


Why should we use singleton pattern instead of static class?

905


how many types of Inheritance?

1134


Is null an object in java?

990


Can we inherit a class with private constructor?

1080