String s1 = "BloodParrot is the man";
String s2 = "BloodParrot is the man";
String s3 = new String("BloodParrot is the man");
System.out.println(s1.equals(s2));
System.out.println(s1 == s2);
System.out.println(s1 == s3);
System.out.println(s1.equals(s3));
//
true
true
false
true を出力
3 つすべてが同じ内容を持っている場合、すべての文字列がメモリ内で同じ場所にないのはなぜですか?