| Author |
Why String is immutable in Java?
|
Rd Dari
Ranch Hand
Joined: Feb 22, 2010
Posts: 194
|
|
Hi all,
Please clear why String is immutable in java with a understandable example?
Thanks !!
|
 |
Jaikiran Pai
Marshal
Joined: Jul 20, 2005
Posts: 8141
|
|
See previous discussions
|
[My Blog] [JavaRanch Journal]
|
 |
Satyaprakash Joshii
Ranch Hand
Joined: Jun 18, 2012
Posts: 72
|
|
|
one reason is..immutable objects are simple...less error prone...once created cant be changed and if multiple threads are accesing at same time still it doesnt cause any issue...
|
 |
 |
|
|
subject: Why String is immutable in Java?
|
|
|