java Integer -Interesting part

2020-09-17
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15

public class Hello {

public static void main(String[] args) {

Integer a = 100;
Integer b = 100;

Integer c = 1000;
Integer d = 1000;

System.out.println(a == b);
System.out.println(c == d);
}
}

output:

1
2
true
false