【单选题】有以下程序输出结果是( )。 #include struct stu {int num; char name[10]; int age;}; void fun(struct stu *p) {printf("%sn",(*p).name);} main() {struct stu students[3]= {{9801,"zhang",20},{9802,"wang",19},{9803,"zhao",18}}; fun(students 2);}
【单选题】设有以下定义 typedef union { long i; int k[5]; char c; } date; struct date { int cat; date cow; double dog; } too; date max; 则语句printf("%d",sizeof(struct date) sizeof(max));的执行结果是( )。
【单选题】根据下面的定义,能打出字母m的语句是( )。 struct person { char name[9]; int age; } struct person class[10]={ 〞john〞,17, 〞paul〞,19, 〞mary〞,18, 〞adam〞,16};
【单选题】下列程序的执行结果为( )。 struct s1 { char *s; int i; struct s1 *sip; } main() { static struct s1 a[]={{"abcd",1,a 1},{"efgh",2,a 2},{"ijkl",3,a}}; struct s1 *p=a;int i=0; printf("%s%s%s",a[0].s,p->s,a[2].sip->s); printf("%d%d",i 2,--a[i].i); printf("%c\n", a[i].s[3]); } a. b. c. d.
【单选题】设有以下语句: struct st{int n;struct st *next;}; static struct st a[3]={5,&a[1],7,&a[2],9,''},*p; p=&a[0]; 则表达式( )的值是6。