单项选择题

有以下程序:
#include <stdio.h>
main()
int a=5,b=1,t;
t=(a<<2)|b;printf("%d\n",t);

程序运行后的输出结果是()

A、21
B、11
C、6
D、1

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

单项选择题
有以下程序: #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

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