FILE fp2;
typedef struct
{UNSIGNED16 port_address;
UNSIGNED16 freshness;
}MSG;
MSG test[2];
test[0].port_address=0x0001;
test[0].freshness=0xFFFF;
test[1].port_address=0x0002;
test[1].freshness=0x0DFE;
if((fp2=fopen("RCVE1.TXT","w+"))==NULL)
{printf("Cannot open this file!\n");
exit(0);
}
for(i=0;i<2;i++)
{
fwrite(test+i,sizeof(MSG),1,fp2);
}
fclose(fp2);
请问我这么输入到文本RCVE1.TXT中的显示形式是0001,FFFF,0002,0DFE