单选题
C语言
题号 #2272914
有以下程序:
#include<stdio.h>
struct S
{int a,b;)data[2]=10,100,20,200);
main( )
{struet S p=data[l];
printf("%d\n",++(p.a));
}
程序运行后的输出结果是( )。
参考答案
D
答案解析
考查结构体的应用,答案为21。
你可能感兴趣的试题
1
有以下程序:
#include<stdio.h>
main( )
{unsigned char a=8,C;
C=a>>3:
printf("%d\n",c);
}
程序运行后的输出结果是( )。
#include<stdio.h>
main( )
{unsigned char a=8,C;
C=a>>3:
printf("%d\n",c);
}
程序运行后的输出结果是( )。
A.32
B.16
C.1
D.0
A.写操作结束后可以从头开始读
B.只能写不能读
C.可以在原有内容后追加写
D.可以随意读和写