package integer;
public class IntegerDemo1 {
public static void main(String[] args) {
int a=128;
Integer i1=Integer.valueOf(a);
Integer i2=Integer.valueOf(a);
System.out.println(i1==i2);
System.out.println(i1.equals(i2));
double dou=123.123;
Double d1=Double.valueOf(dou);
Double d2=Double.valueOf(dou);
System.out.println(d1==d2);
System.out.println(d1.equals(d2));
char c='菜';
Character c1=Character.valueOf(c);
Character c2=Character.valueOf(c);
System.out.println(c1==c2);
System.out.println(c1.equals(c2));
int i= i1.intValue();
System.out.println(i);
double dd=i1.doubleValue();
System.out.println(dd);
byte b=i1.byteValue();
System.out.println(b);
int imax=Integer.MAX_VALUE;
System.out.println(imax);
int imin=Integer.MIN_VALUE;
System.out.println(imin);
long lmax=Long.MAX_VALUE;
System.out.println(lmax);
long lmin=Long.MIN_VALUE;
System.out.println(lmin);
String str="255";
int in=Integer.parseInt(str);
System.out.println(in);
double doub=Double.parseDouble(str);
System.out.println(doub);
}
}
package integer;
public class IntegerDemo2 {
public static void main(String[] args) {
Integer i=1;
int d=i;
System.out.println(i);
System.out.println(d);
}
}