首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
有如下程序 #include<iostream.h> int func(int a,int b) {return(a+b);} void main() { int x=2,y=5,z=8,r; r=func (fun
有如下程序 #include<iostream.h> int func(int a,int b) {return(a+b);} void main() { int x=2,y=5,z=8,r; r=func (fun
admin
2010-03-29
23
问题
有如下程序 #include<iostream.h> int func(int a,int b) {return(a+b);} void main() { int x=2,y=5,z=8,r; r=func (func (x,y),z); cout<<r; 该程序的输出的结果是
选项
A、12
B、13
C、14
D、15
答案
8
解析
语句r=time(func(x,y),z);中, fun(x,y)是一次凋用函数,它的值作为func另一次调用的实参。注意本题调用两次函数。
转载请注明原文地址:https://kaotiyun.com/show/ARjp777K
本试题收录于:
二级C题库NCRE全国计算机二级分类
0
二级C
NCRE全国计算机二级
相关试题推荐
若有以下定义和语句structst{intn;structst*next;};structsta[3]={5,&a[0],6,&a[1],7,&a[2]},*p;p=&a[0]
下面不属于需求分析阶段任务的是()。
设有定义:chars[81];inti=0;,以下不能将一行(不超过80个字符)带有空格的字符串正确读入的语句或语句组是()。
以下选项中,合法的一组C语言数值常量是()。
下列叙述中正确的是
下列关于C语言数据文件的叙述中正确的是()。
下面结构体的定义语句中,错误的是()。
数据库技术的根本目标是()。
以下选项中,不合法的C语言用户标识符是()。
在软件开发中,需求分析阶段产生的主要文档是()。
随机试题
单位商品的价值量与包含在该商品中的社会必要劳动量是()
腹痛肠鸣,泻下粪便臭如败卵,泻后痛减,伴有不消化食物,脘腹痞满,不思饮食,舌苔垢浊,脉滑。证属
关于民法的自愿原则的涵义,下列说法中,不正确的是()。
关于消防疏散说法错误的是()。
下列各项指标中,反映企业营运能力的有()。
(2017·广西)学校文化也称校园文化。()
使用VC6打开考生文件夹下的源程序文件modi2.cpp。请完成函数fun(intx),该函数功能是将x的值转换成二进制数输出到屏幕,并且在函数中调用写函数WriteFile()将结果输出到modi2.txt文件中。例如:x=13,13的二进制
A、 B、 C、 A
Ifoursocietyeverneededareadingrenaissance(复兴),it’snow.TheNationalEndowmentfortheArtsreleased"ReadingatRisk"l
"Laugh,andtheworldlaughswithyou:weep,andweepalone."SowrotethepoetEllaWheelerCox.Emotionsarecatching,andmos
最新回复
(
0
)