题目内容 (请给出正确答案)
[单选题]

若有以下程序 #include <stdio.h> main() { int a=0,b=0,c=0,d; c= (a+=b,, b+=a); /*第4行*/ d=c;; /*第5行*/ ; /*第6行*/ ;printf("%d,%d,%d\n",a,b,c); /*第7行*/ }编译时出现错误,你认为出错的是()

A.第4行

B.第5行

C.第6行

D.第7行

提问人:网友rodyguo 发布时间:2022-01-07
参考答案
查看官方参考答案
如搜索结果不匹配,请 联系老师 获取答案
网友答案
查看全部
  • · 有5位网友选择 A,占比23.81%
  • · 有3位网友选择 C,占比14.29%
  • · 有3位网友选择 C,占比14.29%
  • · 有3位网友选择 D,占比14.29%
  • · 有3位网友选择 B,占比14.29%
  • · 有2位网友选择 B,占比9.52%
  • · 有1位网友选择 A,占比4.76%
  • · 有1位网友选择 D,占比4.76%
匿名网友 选择了A
[125.***.***.143] 1天前
匿名网友 选择了A
[39.***.***.58] 1天前
匿名网友 选择了A
[229.***.***.177] 1天前
匿名网友 选择了C
[6.***.***.228] 1天前
匿名网友 选择了C
[33.***.***.190] 1天前
匿名网友 选择了B
[63.***.***.180] 1天前
匿名网友 选择了D
[199.***.***.188] 1天前
匿名网友 选择了A
[72.***.***.198] 1天前
匿名网友 选择了A
[58.***.***.205] 1天前
匿名网友 选择了B
[235.***.***.176] 1天前
匿名网友 选择了C
[105.***.***.237] 1天前
匿名网友 选择了B
[82.***.***.101] 1天前
匿名网友 选择了D
[124.***.***.125] 1天前
匿名网友 选择了C
[180.***.***.181] 1天前
匿名网友 选择了C
[176.***.***.231] 1天前
匿名网友 选择了D
[54.***.***.44] 1天前
匿名网友 选择了B
[188.***.***.89] 1天前
匿名网友 选择了B
[114.***.***.28] 1天前
匿名网友 选择了A
[188.***.***.178] 1天前
匿名网友 选择了C
[0.***.***.99] 1天前
加载更多
提交我的答案
登录提交答案,可赢取奖励机会。
更多“若有以下程序 #include <stdio.h> main…”相关的问题
第1题
#include <stdio.h> main() { int a = 3; do { printf("%d,", a-=2 ); } while( ! (--a) ); printf("\n"); } 程序运行后的输出结果是 (难度系数★★★)

A、1,-2

B、0,-1

C、-2,1

D、0,0

点击查看答案
第2题
有以下程序 #include <stdio.h> main() { int a=2, c=5; printf( "a=%%d,b=%%d\n", a,c ); } 程序的输出结果是( )

A、a=2,b=5

B、a=%2,b=%5

C、a=%d,b=%d

D、a=%%d,b=%%d

点击查看答案
第3题
有以下程序   #include <stdio.h>   main()   { int a=2,b=2,c=2;   printf("%d\n",a/b&c);   } 程序运行后的输出结果是

A、0

B、1

C、2

D、3

点击查看答案
第4题
以下程序 #include <stdio.h> main() { int a = -2, b = 0; while (a++ && ++b) ; printf("%d,%d\n", a, b ); } 程序运行后输出结果是 (难度系数★★)

A、1,2

B、-2,0

C、-1,1

D、0,0

点击查看答案
第5题
若有以下程序 #include <stdio.h> main(){ int a=1,b=2,c=3,d=4,r=0; if(a!=1) ; else r=1; if(b==2) r+=2; else; if(c!=3) r+=3; else; if(d==4) r+=4; printf("%d\n",r); }

A、10

B、7

C、6

D、3

点击查看答案
第6题
有以下程序: #include <stdio.h> . main() {int al=0,a2=0,a3=0; char ch; while((ch=getchar())!='\n') switch(ch) {case 'A':a1++; case 'B':a2++; default:a3++; } printf("%d,%d,%d",a1,a2,a3);} 现从键盘上输入AAAAABBBC <回车> ,则程序执行后的输出结果是( )

A、5,8,9

B、5,3,1

C、5,3,9

D、5,8,1

点击查看答案
第7题
有以下程序 #include <stdio.h> int main() {int a=1,b=2,c=3,d=0; if(a==1) if(b!=2) if(c==3) d=1; else d=2; else if(c!=3) d=3; else d=4; else d=5; printf("%d\n",d); } 程序运行后的输出结果是 。
点击查看答案
第8题
1. 阅读并分析程序 #include <stdio.h> int main() { char c1,c2; c1=’a’; c2=’b’; printf(“c1 is %c\nc2 is %c\n”,c1,c2); printf(“c1 is %d\nc2 is %d\n”,c1,c2); return 0; } l 请问,程序的运行结果是 。 l 请增加一条语句,用十六进制格式输出c1和c2的数值。 请增加:使c1的值加3,c2的值减1,并重新输出c1和c2的数值。
点击查看答案
第9题
有以下程序:#include "stdio.h" #include <stdlib.h> int main() { int *q,*p; p=(int *) malloc(sizeof(int)*20); q=p; scanf("%d%d",p,q); printf("%d,%d\n",*p,*q); return 0; } 若从键盘输入:10 20↙,则程序运行结果是()。

A、20,20

B、10,20

C、20,10

D、10,10

点击查看答案
第10题
有以下程序: #include<stdio.h> int a=5; void fun(int b) { int a=10; a+=b; printf("%d",a); } void main() { int c=20; fun(c); a+=c; printf("%d\n",a); } 请写出程序的运行结果。
点击查看答案
账号:
你好,尊敬的用户
复制账号
发送账号至手机
密码将被重置
获取验证码
发送
温馨提示
该问题答案仅针对搜题卡用户开放,请点击购买搜题卡。
马上购买搜题卡
我已购买搜题卡, 登录账号 继续查看答案
重置密码
确认修改
欢迎分享答案

为鼓励登录用户提交答案,简答题每个月将会抽取一批参与作答的用户给予奖励,具体奖励活动请关注官方微信公众号:简答题

简答题官方微信公众号

警告:系统检测到您的账号存在安全风险

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

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