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

Explain the differences between public, private, protected
and static?

Answer Posted / manne ranjith

public-->inherite the protected members as preotected in
drived class and pubic members wiull be public in derived
class

protected--->pubic and protecated members of the base class
will become protected in derived class

Private-->pubilc and proteacted members will become private
in derived class

static--->Method is defined by static cannot access non-static
members or fields of that class. But non-static members can
access static fields or methods.

Is This Answer Correct ?    28 Yes 32 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many bytes is double?

976


How do you sort a list in java?

1036


What is the difference between arraylist and hashset in java?

1155


Can inner class extend any class?

1059


In the below example, what will be the output?

1031


How will you reverse a link list without using recursion?

1039


What is keyword auto for?

1188


Is math an abstract class in java?

1015


What are the 4 versions of java?

1169


What are the types of java?

1106


Why we used vector class?

1070


Can we declare an array without size in java?

1012


What is java string pool?

1010


What do you understand by synchronization?

1052


What is boolean used for?

1038