首页
外语
计算机
考研
公务员
职业资格
财经
工程
司法
医学
专升本
自考
实用职业技能
登录
计算机
若有如下Sub过程: Sub sfun(x As Single,y As Single) t=x x=t/y y=tMod y End Sub 在窗体中添加一个命令按钮Command33,对应的事件过程如下: Ptivate Sub Command33_C
若有如下Sub过程: Sub sfun(x As Single,y As Single) t=x x=t/y y=tMod y End Sub 在窗体中添加一个命令按钮Command33,对应的事件过程如下: Ptivate Sub Command33_C
admin
2021-09-06
24
问题
若有如下Sub过程:
Sub sfun(x As Single,y As Single)
t=x
x=t/y
y=tMod y
End Sub
在窗体中添加一个命令按钮Command33,对应的事件过程如下:
Ptivate Sub Command33_Click()
Dim a As Single
Dim b As Single
a=5:b=4
sfun(a,b)
MsgBox a&chr(10)+chr(13)&b
End Sub
打开窗体运行后,单击命令按钮,消息框中有两行输出,内容分别为( )。
选项
A、l和1
B、1.25和1
C、1.25和4
D、5和4
答案
B
解析
此题中设定了一个sfun()函数,进行除法运算和求模运算。命令按钮的单击事件中,定义两变量a=5,b=4,调用sfun函数传递a,b的值给x,y进行运算,t=x=5,y=4;x=t/y=5/4=1.25(除法运算);y=tMody=5mod4=1(求模运算)。Sfun函数参数没有指明参数传递方式,则默认以传址方式传递,因此a的值为1.25,b的值为1。
转载请注明原文地址:https://kaotiyun.com/show/jWvp777K
本试题收录于:
二级Access题库NCRE全国计算机二级分类
0
二级Access
NCRE全国计算机二级
相关试题推荐
通过关联关键字”系别“这一相同字段,下图在表二和表一构成的关系式()。
有三个关系R,S和T如下图所示:其中三个关系对应的关键字分别为A,B和复合关键字(A,B)。则T的记录项(b,q,4)违反了
软件生命周期可分为定义阶段、开发阶段和维护阶段,下面属于开发阶段任务的是
某系统结构图如下图所示,该系统结构图的最大扇出数是
若“学生基本情况”表中政治面貌为以下4种之一:群众、共青团员、党员和其他,为提高数据输入效率,可以设置字段的属性是
下列叙述中正确的是()。
在满足实体完整性约束的条件下
在宏表达式中要引用Form1窗体中的txt1控件的值,正确的引用方法是()。
设一棵树的度为3,其中没有度为2的结点,且叶子结点数为6。该树中度为3的结点数为
以下程序的功能是计算并输出两个整数的最大公约数。PrivateSuba1()DimxAsInteger,yAsInteger,tAsIntegerx=lnputBox("请输入x的值")y=Inpu
随机试题
如果被保险货物运达保险单所载明的目的地,收货人提货后即将货物转运,则保险公司的保险责任于转运到达目的地仓库时终止。()
国家公务员在对外交往中损害国家荣誉和利益的行为直接违反了
舒张早期奔马律与生理性第三心音的区别不包括
A.白庀B.白屑风C.油风D.花斑癣E.头藓
我国急性胰腺炎的最常见病因为
“绿色包装”就是指所使用材料中的主要成分没有受到污染,且可回收利用、可降解。()
在最佳现金持有量确定的存货模式下,企业持有的现金数量越少,则()。
在组织运行过程中,组织冲突的发生()。
热爱祖国,热爱人民,拥护中国共产党领导,拥护社会主义。全面贯彻国家教育方针,自觉遵守教育法律法规,依法履行教师职责权利。不得有违背党和国家方针政策的言行。这体现了教师职业道德规范的()
2015年3月24日,中共中央政治局审议通过广东、天津、福建自由贸易试验区总体方案,进一步深化上海自由贸易试验区改革实验方案。其中主要发展对台湾地区和东盟贸易的自贸区是()。
最新回复
(
0
)