This is a question that I got in an interview.
I\'ve two strings defined as
String s1=\"Java\";
String s2=\"Java\";
My question i
YES, Andrew Hare was answer on stack overflow in this link https://stackoverflow.com/a/2486195/4835894.
Basically, a string intern pool allows a runtime to save memory by preserving immutable strings in a pool so that areas of the application can reuse instances of common strings instead of creating multiple instances of it.