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

string is immutable? right every one knows that, my
question is it advantage or disadvantage making string
immutable?

Answer Posted / payal gupta

It is an advantage that a String class is immutable because
almost all the standard classes use its methods, if they
were mutable, then the behaviour of other standard classes
and their methods would not have been consistent.

Is This Answer Correct ?    7 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is string builder not thread safe?

1013


How does regex work?

907


Difference between character constant and string constant in java ?

960


Is set ordered in java?

942


can java object be locked down for exclusive use by a given thread? : Java thread

1021


Is static a keyword in java?

918


What are the steps involved to write rmi based programs?

950


What is use of inner class in java?

1036


Do I need java for windows 10?

977


Can we write class inside a class in java?

920


What is the replace tool?

1066


Explain when classnotfoundexception will be raised ?

982


What is intern method in java?

1025


Which one of the following suits the description of a string better: derived or primitive?

903


How transient variable is different from volatile variable?

1017