单项选择题
设有下列程序段: char s[20]="Beijing",*p; p=s; 则执行p=s;语句后,下列叙述正确的是( )。
A.可以用*p表示s[0]
B.s数组中元素的个数和p所指字符串长度相等
C.s和p都是指针变量
D.数组s中的内容和指针变量p中的内容相同
点击查看答案&解析
<上一题
目录
下一题>
热门
试题
单项选择题
下列错误的定义语句是( )。
A.int x[ ][3]={{0},{1},{1,2,3}};
B.int x[4][3]={{1,2,3},{1,2,3},{1,2,3},{1,2,3}};
C.int x[4][ ]={{1,2,3},{1,2,3},{1,2,3},{1,2,3}};
D.int x[ ][3]={1,2,3,4};
点击查看答案&解析
单项选择题
有下列程序: #include <stdio.h> main() {int a[]={1,2,3,4},y,*p=&a[3]; --p; y=*p; printf( y=%d n ,y); } 程序的运行结果是( )。
A.y=0
B.y=1
C.y=2
D.y=3
点击查看答案&解析
相关试题
有下列程序: #include <stdio.h> ...
有下列程序: #include <stdio.h> m...
有下列程序: #include <stdio.h> ...
有下列程序: #include <stdio.h> v...
有下列程序: #include <stdio.h> m...