Java学习之数据类型


八大基本数据类型(首字母小写)

    boxing(装箱)让基本的数据类型拥有一些对数据处理的能力。

以int型为例:Integer.BYTES(长度)

      Integer.MAX-VALUE(最大值)

      Integer.MIN-VALUE(最小值)

      Integer.SIZE(占多少位bit)

int(Integer)

double(Double)

char(Character)

float(Float)

byte(Byte)

long(Long)

short(Short)

boolean(Boolean)

复杂数据类型(首字母大写):复杂数据类型,不但可以存储数据,还会拥有一些对数据的处理能力。

String s="hello world";

s.toUpperCase();<转成大写字母>

s.toLowerCase();<转成小写字母>

s.Length();<长度>