I think I found a contradiction. In JavaSyntaxZero Level 3 Lecture 6, this is said about strings: However, in the previous lecture, it shows two strings with the exact same text, having different references that point to memory: Could somebody explain why the strings with identical text have different references?