是不是写错了?
Topic sourcetypedef struct
{
char n1;
char n2;
char n3;
char n4;
} IP;
typedef union
{
IP ip;
int addr;
} IP_ADDR;
- 1
typedef struct
{
char n1;
char n2;
char n3;
char n4;
} IP;
typedef union
{
IP ip;
int addr;
} IP_ADDR;
绊倒铁盒
而在C语言中,我们可以很方便地用struct、union来处理字节,以及字节和int,float的转换
上句中提到在C语言中使用struct处理数据的转换,struct是结构体的意思吧,可以用来表示对象.至于数据转换有这个功能吗?