柠檬试题库
search
首页
计算机
公务员
驾照
关于
share
若有以下程序段 char str[4][12]={ "aa","bbb","ccccc","d" } , *strp[4]; int i; for( i = 0; i< 4; i++ ) strp[i] = str[i]; 不能正确引用字符串的选项是
A.str[0]
B.strp
C.strp[3]
D.*strp
热度🔥444
参考答案:B
解析:
【解析】本题考查对字符数组中字符的引用。指针数组strp表示每一个数组元素都存放了一个字符串的首地址。选项B代表指针数组strp的第一个数组元素的地址,不是对字符的引用。所以选项B正确。
复制题目向AI提问
content_copy
content_copy
扫码免费计算机二级刷题
2025年计算机等级考试题库
推荐
RAM的特点是()。
有以下程序 #include #include struct A { int a; char b[10]; double c;}; void f(struct A t); main() { struct A a={1001,"ZhangDa",1098.0}; f(a); printf("%d,%s,%6.1f\n", a.a,a.b,a.c); } void f(struct A t) { t.a=1002; strcpy(t.b,"ChangRong"); t.c=1202.0;} 程序运行后的输出结果是
有以下程序 #include fun( int a, int b ) { int static m=0, i=2; i=i+m+1; m=i+a+b; return m; } main() { int k=4, m=1, p; p=fun( k, m); printf("%d,",p); p=fun( k, m); printf("%d\n",p); } 程序运行后的输出结果是
在软件开发中,需求分析阶段可以使用的工具是( )。
标签
二级C语言
strp
数组
str
引用