Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardJavaInteger caching identitySingle-choice MCQ

What is printed, and why does it differ from the usual Integer-identity expectation?

Integer x = 1000; int y = 1000; System.out.println(x == y);