java 中各个数据类型所占的字节数

boolean   这个试编译环境而定

byte  1个字节

short 2个字节

char  2个字节

int   4个字节

long  8个字节

float 4个字节

double 8个字节
原文地址:https://www.cnblogs.com/hzcya1995/p/13318124.html