题目内容 (请给出正确答案)
[主观题]

有以下程序#include <stdio.h>#include <string.h>main(){ char str[ ][20]=

有以下程序

#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

查看答案
如搜索结果不匹配,请 联系老师 获取答案
您可能会需要:
您的账号:,可能会需要:
您的账号:
发送账号密码至手机
发送
更多“有以下程序#include <stdio.h>#includ…”相关的问题

第1题

有以下程序#include <stdio .h> main (){ printf("%d\n", NULL); }A.0B.1C.-1D.NULL没定义,出错

有以下程序 #include <stdio .h> main () { printf("%d\n", NULL); }

A.0

B.1

C.-1

D.NULL没定义,出错

点击查看答案

第2题

有以下程序:#include <stdio, h>void sum(int a[ ] ){a[0]=a[-1] +a[1];}main (){int a[10] = {

有以下程序:#include <stdio, h>void sum(int a[ ] ){ a[0]=a[-1] +a[1];}main (){ int a[10] = {1,2,3,4,5,6,7,8,9,10}; sum(&a[2]); prinff("% d \n",a[2]); }程序运行后的输出结果是()。

A.6

B.7

C.5

D.8

点击查看答案

第3题

有以下程序:#include <stdio, h>main (){int a =666,b =888;printf("%'d \n", a,b); 程序运行

有以下程序: #include <stdio, h> main () { int a =666,b =888; printf("%'d \n", a,b); 程序运行后的输出结果是()。

A.错误信息,

B.666

C.888

D.666,888

点击查看答案

第4题

有以下程序:#include <stdio, h>main(){char a1 ='M',a2 ='m'; printf("%c\n",(a1,a2));} 以下

有以下程序:#include <stdio, h>main(){ char a1 ='M',a2 ='m'; printf("%c\n",(a1,a2)); } 以下叙述中正确的是()。

A.程序输出大写字母M

B.程序输出小写字母m

C.格式说明符不足,编译出错

D.程序运行时产生出错信息

点击查看答案

第5题

有以下程序:#include <stdio, h>main(){int m =0256,n =256;printf("% o % o \n" ,m,n); 程序

有以下程序: #include <stdio, h> main() { int m =0256,n =256; printf("% o % o \n" ,m,n); 程序运行后的输出结果是() 。

A.0256 0400

B.0256 256

C.256 400

D.400 400

点击查看答案

第6题

有以下程序:#include <stdio, h>#define f(x) (x * x)main (){ int i1 ,i2;i1 = f(8)/f(4) ;i2

有以下程序:#include <stdio, h>#define f(x) (x * x)main (){ int i1 ,i2; i1 = f(8)/f(4) ;i2 =f(4 +4)/f(2 +2); printf("% d,% d\n" ,i1 ,i2);

A.64,28

B.4,4

C.4,3

D.64,64

点击查看答案

第7题

有以下程序:#include <stdio, h>#include <string, h>struet STU{ int nam;float TotalSeore;};v

有以下程序:#include <stdio, h>#include <string, h>struet STU{ int nam; float TotalSeore;};void f(strnct STU p){ struct STU s[2] = { {20044,550} ,{20045,537} }; p.num = s [1]. num; p.TotalScore = s [1]. TotalScore;main(){ struct STU s[2] = {{20041,703} ,{20042,580}}; f(s[0] ); printf("%d %3.Of\n" ,s[0].num,s[0].TotalSeore); }程序运行后的输出结果是()。

A.20045 537

B.20044 550

C.20042 580

D.20041 703

点击查看答案

第8题

有以下程序: #include <stdio, h>main () {int k=5,n =0; while (k>0){switch (k) {default: b

有以下程序: #include <stdio, h>main () { int k=5,n =0; while (k>0) { switch (k) { default: break; case 1 : n+ =k; case 2 : case3 : n+ =k; } k--; printf("% d \n" ,n);}程序运行后的输出结果是()。

A.0

B.4

C.6

D.7

点击查看答案

第9题

有以下程序:#include <stdio, h>void fun(iht * a,int i,int j){int t;if(i < j) {t=a[i];a[i] =

有以下程序:#include <stdio, h>void fun(iht * a,int i,int j){ int t; if(i < j) { t=a[i];a[i] =a[j] ;a[j]=t; i++;j--; fun(a,i,j);main () int x[ ]: {2,6,1,8} ,i; fun(x,0,3); for(i=0;i <4;i ++ ) printf("%2d" ,x[i] ); printf(" \n");

A.1268

B.8621

C.8162

D.8612

点击查看答案

第10题

有以下程序:#include <stdio, h>main() {char c1='1',c2='2';c1=getchar();c2=getchar();putcha

有以下程序:#include <stdio, h>main() { char c1='1',c2='2'; c1=getchar();c2=getchar();putchar(c1);putchar(c2); } 当运行时输入:a<回车>后,以下叙述正确的是()。

A.变量c1被赋予字符a,c2被赋予回车符

B.程序将等待用户输入第二个字符

C.变量c1被赋予字符a,c2中仍是原有字符2

D.变量c1被赋予字符a,c2中将无确定值

点击查看答案

第11题

有以下程序: #include <stdio, h>int a =2;int f(int n){ static int a: 3;intt=0;if(n%2){ stat

有以下程序: #include <stdio, h>int a =2;int f(int n){ static int a: 3; int t=0; if(n%2){ static int a=4;t+ =a++;} else { static int a=5;t+ :a++;} return t + a + +;main (){ int s=a,i; for(i=0;i<3;i++)s + =f(i); prinff("% d \n" ,s); }程序运行后的输出结果是()。

A.26

B.28

C.29

D.24

点击查看答案
发送账号至手机
获取验证码
发送
温馨提示
该问题答案仅针对搜题卡用户开放,请点击购买搜题卡。
马上购买搜题卡
我已购买搜题卡, 登录账号 继续查看答案
重置密码
确认修改
温馨提示
每个试题只能免费做一次,如需多次做题,请购买搜题卡
立即购买
稍后再说
警告:系统检测到您的账号存在安全风险

为了保护您的账号安全,请在“赏学吧”公众号进行验证,点击“官网服务”-“账号验证”后输入验证码“”完成验证,验证成功后方可继续查看答案!

微信搜一搜
赏学吧
点击打开微信
警告:系统检测到您的账号存在安全风险
抱歉,您的账号因涉嫌违反赏学吧购买须知被冻结。您可在“赏学吧”微信公众号中的“官网服务”-“账号解封申请”申请解封,或联系客服
微信搜一搜
赏学吧
点击打开微信