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

What is the use of static keyword in "public static void
main()"

Answer Posted / rasool

The public keyword is an access specifier, which allows the
programmer to control the visibility of class members. When
a class member is preceded by public, then that member may
be accessed by code outside the class in which it is
declared.In this case, main( ) must be declared as public,
since it must be called by code outside of its class when
the program is started. The keyword static allows main( ) to
be called without having to instantiate a particular
instance of the class.

Is This Answer Correct ?    2 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why Java doesn’t support multiple inheritance?

1089


what is comparable and comparator interface?

1044


What is enhanced loop in java?

1052


Which method you will use to create a new file to store some log data. Each time a new log entry is necessary, write string to the file in java ?

1211


How is a variable stored in memory?

1067


What do you mean by exception handling in Java?

1366


What is use of super keyword in java?

1084


What is 32 bit float?

1059


How to store image in arraylist in java?

1025


What is meant by 'bit masking' in java?

1260


What is main in java?

1211


What are default methods ?

1107


Is it possible to specify multiple jndi names when deploying an ejb?

1053


What are class types in java?

1115


What is difference between string and new string?

1080