首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
编写如下程序: Private Sub Command1_Click() Dim x As Integer x = 10 Print fun1(x, 12) + x End Sub Private Function fun1(m As I
编写如下程序: Private Sub Command1_Click() Dim x As Integer x = 10 Print fun1(x, 12) + x End Sub Private Function fun1(m As I
admin
2020-07-22
19
问题
编写如下程序:
Private Sub Command1_Click()
Dim x As Integer
x = 10
Print fun1(x, 12) + x
End Sub
Private Function fun1(m As Integer, n As Integer) As Integer
If n > 10 Then m = n
fun1 = m + n
End Function
程序运行后,单击命令按钮Command1,输出结果为
选项
A、30
B、32
C、34
D、36
答案
D
解析
Function fun1函数中的参数都是引用传递,会改变实参的值,执行完后Command1_Click中变量x的值为12。选D)。
转载请注明原文地址:https://jikaoti.com/ti/DBS0FFFM
本试题收录于:
二级VB题库NCRE全国计算机二级分类
0
二级VB
NCRE全国计算机二级
相关试题推荐
下列选项中不符合良好程序设计风格的是
在结构化程序设计中,模块划分的原则是
设变量x中的值是395,则下面语句的输出是Printx\100+((xMod100)\10)*10+(xMod10)*100
窗体上有一个名称为Option1的单选按钮数组,程序运行时,当单击某个单选按钮时,会调用下面的事件过程:PrivateSubOption1_Click(IndexAsInteger)…EndSub下面关于此过程的参数Ind
下面描述中不属于数据库系统特点的是()。
下列符号常量的声明中不合法的是
将E-R图转换为关系模式时,实体和联系都可以表示为( )。
在关系数据库中,用来表示实体间联系的是
随机试题
下列关于劳动争议仲裁时效的表述错误的是()
Thechildrenareas______aslarks.
下列案件中,导致立案管辖和审判管辖的主体重合的是:()
为社会提供检测或校准服务的实验室为()。
班级授课辅助的教学组织形式是()。
信念的特征表现在,它具有()
(16年)设矩阵,且方程组Aχ-β无解.(Ⅰ)求a的值;(Ⅱ)求方程组ATAχ=ATβ的通解.
操作数地址的16位偏移量(又称有效地址EA)直接包含在指令中,紧跟在操作码之后,存放在代码段区域的寻址方式是
Onthefirstdayofschooloneofmyclassmatesbeganatalkwithmethatchangedmylife.Shesaid,"Hi,handsome.MynameisR
ShouldWeEmbraceCyberspeak?1.越来越多的网络用语渗透到日常口语和书面语中2.有人认为这是语言发展的结果,也有人认为这是对语言的污染3.我的看法
最新回复
(
0
)