单项选择题

有以下程序:
#include <stdio.h>
#include <string.h>
main()
char str[][20]="One * World","One * Dream!",*p=str[1];
printf("%d," ,strlen(p));printf("%s\n" ,p);

程序运行后的输出结果是

A、 9,One * World
B、 9,One * Dream!
C、 10,One * Dream!
D、 10,One * World

<上一题 目录 下一题>
热门 试题

单项选择题
阅读下列程序,当运行函数时,输入abc de fg z10,则输出为 #include <stdio.h> #include <ctype.h> #include <string.h> int fun (char *str) int i,j=0; for(i=0;str[i]!=' 0';i++) if(str[i]!='') str[j++]=str[i]; str[j]=' 0'; main() char str[81]; int n; printf( Input a string: ); gets(str); puts(str); fun(str); printf( %s n ,str);

A、 abc
B、 z10
C、 abc de fg z10
abcdefgz10
D、 abc de fg z10

单项选择题
设有以下说明语句: struct ex int x;float y;char z; example; 则下面的叙述中不正确的是()

A、 struct是结构体类型的关键字
B、 example是结构体类型名
C、 x,y,z都是结构体成员名
D、 struct ex是结构体类型名

相关试题
  • 有以下程序: #include <stdio.h> m...
  • 有以下程序: #include <stdio.h> m...
  • 以下程序的输出结果是______。 #in...
  • 设有以下定义和语句,则*(*(p+2)+...
  • 函数my_cmp()的功能是比较字符串s和t的...