1B (byte字节) = 8bit (位) (固定构成)
32位编译器:
char: 1byte
char * (指针变量): 4byte (32位的寻址空间是2^32,即32个bit,也就是4byte;同理64位编译器)
short int: 2byte
int: 4byte
unsigned int: 4byte
float: 4byte
double: 8byte
long: 4byte
long long: 8byte
unsigned long: 4byte
64位编译器:
char: 1byte
char * (指针变量): 8byte
short int: 2byte
int: 4byte
unsigned int: 4byte
float: 4byte
double: 8byte
long: 8byte
long long: 8byte
unsigned long: 8byte
输出对应字节数:
sizeof()