Can someone explain me on how String class behaves in memory management in java. I have lately heard about string comparison. how does two string with == operator and equals method differ.
example:
String str1 = "Hello";
String str2 = "Hello";
String str3 = new String("Hello");
any suggestions on case 1 AND case3?