0 votes
in JAVA by
Does String is thread-safe in Java?

1 Answer

0 votes
by

Strings are immutable, so we can’t change it’s value in program. Hence it’s thread-safe and can be safely used in multi-threaded environment.

Related questions

0 votes
asked Apr 14, 2023 in JAVA by SakshiSharma
+1 vote
asked May 30, 2020 in JAVA by Robindeniel
...