我知道'enum'数据类型是用户定义的数据类型,'enum'变量是'int'的大小.
我知道'enum_variable'的大小为32位,不是强制性的.但这里的混淆部分是32位[if]如何共同存储所有'枚举'值?
enum identifier
{
value1 = 0, value2 = 20, value3 = 7000, value4 = 1234567
} enum_variable;
printf("%d\n",sizeof(enum_variable));
Run Code Online (Sandbox Code Playgroud)