Frage im Vorstellungsgespräch bei UST

Why string is immutable in java?

Antwort im Vorstellungsgespräch

Anonym

24. Feb. 2020

because of stringpool concept. stringpool will have unique strings and which will be shared across the application, if someone changes the string value in one place, then the other referred string variable should not get affected.