若有如下结构体说明: struct STRU {int a,b;char c:double d; stmct STRU*p1,*p2;
第1题
若有如下结构体说明
struct STRU
{ int a, b: char c;double d:
struct STRU p1,p2;
};
请填空,以完成对t数组的定义,t数组的每个元素为该结构体类型
______t[20];
第2题
A.以上的说明形式非法
B.ST是一个结构体类型
C.NEW是一个结构体类型
D.NEW是一个结构体变量
第3题
第4题
若有以下说明和语句
struct student
{int age;
int num;
}std, *p;
p=&std;
则以下对结构体变量std中成员age的引用方式不正确的是( )。
A.std.age B.p->age C.(*p).age D.*p.age
第5题
A.year=1958;
B.birthday.year=1958;
C.person.birthday.year=1958;
D.person.year=1958;
第6题
A.A.STD tt[2]={{1,'A',62},{2,'B',75}};
B.B.STD tt[2]={1,"A",62},2,"B",75};
C.C.struct tt[2]={{1,'A'},{2,'B'}};
D.D.struct tt[2]={{1,"A",62.5},{2,"B",75.0}};
第7题
以下程序用来输出结构体变量ex所占存储单元的字节数,请填空。
struct st
{char name[20];double score;};
main()
{struct st ex;
printf("ex size:%d\n",sizeof(______);
}
第8题
第9题