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

Need to use public,static keywords in main function?

Answer Posted / psreddy

public access modifier we declared then that class visible
to every where and access to any where
bcoz if we write any number business logic classes but
we have to write only one execution logic class for all
these business logic classes
that is why always execution logic class as public
and also there is need of writing static key word
bcoz the execution logic executes only once
other wise we will get runtime exeption

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between numeric and integer?

1059


Can we override tostring method in java?

1009


Can an interface extend another interface?

1109


What is substring 1 in java?

1235


What is a Null object?

1726


why are there separate wait and sleep methods? : Java thread

1081


Is string serializable in java?

1069


Why webdriver is an interface?

1091


What is boolean used for?

1090


Explain about method local inner classes or local inner classes in java?

1068


What is difference between this and super keyword?

1043


Why string is immutable or final in java

1139


What does split function do in java?

1078


What is the difference between access specifiers and access modifiers in java? 16

1051


State differences between C and Java?

1264