定义以下结构体类型struct s{ int x;float f;}a[3];语句printf("%d",sizeof(a))的输出结果为
查看答案
若有下列定义:struct b{ float a[5];int d;}x; 则变量x在内存中所占的字节为下列哪一个:
A. 6
B. 10
C. 24
D. 30
struct contry{int num;char name[20];}x[5]={1,"China",2,"USA",3,"France",4,"Englan",5,"Spanish"};main(){int i;for (i=3;i<5;i++)printf("%d%c",x[i].num,x[i].name[0]);}的运行结果为4E5S
A. 对
B. 错
定义以下结构体数组struct{int num;char name[10];}x[3]={1,"china",2,"USA",3,"England"};语句printf("\n%d,%s",x[1].num,x[2].name)的输出结果为2,USA
A. 对
B. 错
定义以下结构体数组struct c{ int x;int y;}s[2]={1,3,2,7};语句printf("%d",s[0].x*s[1].x)的输出结果错误的是:
A. 14
B. 6
C. 21
D. 2