首页 > 代码库 > java基础类型、包装器

java基础类型、包装器

char a = ‘h‘;      

//类包装器

Character aobj = a ;//自动装箱

byte b = 6;     

Byte bobj = b;

short s = 234;

Short sobj = s;

boolean b = true;

Boolean bobj = b;

int i = 100;

Integer iobj = i;

long l = 567L;

Long lobj = l;

float f = 8.99F;

Float fobj = f;

double d = 4.7788;

Double dobj = d;

int aa = a + i;

java基础类型、包装器