public class Client {
public static void main(String[] args) {
Integer aa = new Integer(100);
Integer bb = new Integer(100);
System.out.println("new 产生的对象:aa==bb : " + (aa==bb));
System.out.println("new 产生的对象:aa.equals(bb) : " + (aa.equals(bb)));
Integer aa2 = 100;
Integer bb2 = 100;
System.out.println("基本类型 产生的对象:aa2==bb2 : " + (aa2==bb2));
System.out.println("基本类型 产生的对象:aa2.equals(bb2) : " + (aa2.equals(bb2)));
Integer aa3 = Integer.valueOf(100);
Integer bb3 = Integer.valueOf(100);
System.out.println("Integer.valueOf 产生的对象:aa3==bb3 : " + (aa3==bb3));
System.out.println("Integer.valueOf 产生的对象:aa3.equals(bb3) : " + (aa3.equals(bb3)));
Integer j = new Integer(102);
compare(i, j);*/
}
System.out.println(i == j);
System.out.println(i > j);
System.out.println(i < j);
}*/
}