首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
单击命令按钮时,下列程序代码的执行结果为 ( ) Function FirProc(x As Integer, y As Integer, z As Integer) FirProc=2*x+y+3*z End Fu
单击命令按钮时,下列程序代码的执行结果为 ( ) Function FirProc(x As Integer, y As Integer, z As Integer) FirProc=2*x+y+3*z End Fu
admin
2010-03-30
20
问题
单击命令按钮时,下列程序代码的执行结果为 ( ) Function FirProc(x As Integer, y As Integer, z As Integer) FirProc=2*x+y+3*z End Function Function SecProc(x As Integer, y As Integer, z As Integer) SecProc=FirProc(z, x, y)+x End Function Private Sub Commandl Click() Dim a As Integer, b As Integer, c As Integer a=2 :b=3 :c=4 Print SecProc(c, b,A)End Sub
选项
A、21
B、19
C、17
D、34
答案
1
解析
执行语句Print SecProc (c,b,a)时,调用SecProc函数,此时将实参c, b,a的值对应传递给形参x,y,z。得SecProc =FirProc(a,c,b)+c,此时又需要调用Fir- Proc函数将a,c,b的值传递给对应形参x,y, z。在FirProc函数中执行语句FirProc=2*x +y+3*z即执行语句FirProe=2*a+c+3 *b其结果值为2*2+4+3*3即17。故 FirProe(a,c,b)的返回值为17。再与c相加即得SecProc函数的返回值结果21。选项A正确。
转载请注明原文地址:https://jikaoti.com/ti/1qg0FFFM
本试题收录于:
二级VB题库NCRE全国计算机二级分类
0
二级VB
NCRE全国计算机二级
相关试题推荐
Java对象串行化技术,主要是通过ObjectInputStream类和【】类来实现的。
下面的代码实现一个简单的Applet:importjava.applet.Applet;importjava.awt.*;publicclassSampleextendsApplet{private
关系中的属性或属性组合,其值能够唯一地标识一个元组,该属性或属性组合可选做为【】。
已知二叉树的前序序列为ABDCEFG,中序序列为DBCAFEG,则其后序序列为()。
在结构化设计方法中,数据流图表达了问题中的数据流与加工间的关系,并且每一个______实际上对应一个处理模块。
软件结构是以______为基础而组成的一种控制层次结构。
在计算机中,算法是指( )。
在Java中,能实现多重继承效果的方式是
关于Applet执行的操作,下面说法正确的是
下列不是表达式语句的是( )。
随机试题
裂变思维是指在思考和解决问题时,不受已知的或现成的方式、规则和范畴的约束,从一个问题的中心点向外辐射发散,进行多方向、多角度、多层次的思维活动。根据上述定义,下列情形体现了裂变思维的是:
下面有关处方的说法中正确的是
下列何种纤维面层的地毯阻燃性最好?[2012—043,2009—048,2007—046]
(2003)在处理公共建筑室外空间与周围环境的关系时.常常会引用“巧千因借,精在体宜”及“俗则摒之,嘉则收之”.这些话出自于:
X股份有限公司(以下简称X公司)系公开发行A股的上市实体,北京ABC会计师事务所注册会计师A担任X公司2014年度财务报表审计的项目经理,注册会计师B为主任会计师。资料一:A注册会计师在审计工作底稿中记录了所了解的X公司情况及其环境,部分内容摘录
案例一:以下是《十几减九》的教学片段:教师先让学生独立思考例题“12—9”的计算方法,然后展开师生对话,交流算法。师:谁来介绍自己的方法,告诉大家你是怎么想的?生1:我是数出来的。师:你是怎么数出来的呢?
行政行为合法要件包括()。
2016年可以被称为“共享年”,截至2016年11月,已经诞生了摩拜、优拜、OFO、小鸣、骑呗等多家共享单车品牌。针对上述5种单车品牌,武汉大学樱园宿舍的门前,特意设立了共享单车小车位。车位1至5从左到右停着5辆不同品牌不同颜色的单车,其中一辆为红色,并已
已知fˊ(lnx)=1+x,则f(x)=_________.
Thegrandmotherdidn’twanttogotoFlorida.ShewantedtovisitsomeofherconnectionsineastTennesseeandshewasseizing
最新回复
(
0
)