单选题 VB
题号 #2029815


进入在线模考

参考答案

B

答案解析

B)    【解析】本题考查选择语句。选择语句形式一般分为两种,如果分支语句If和Then在同一行,不需要写上End If语句,否则必须加上EndIf语句。题目中x的初值为5,大于0,因此执行if语句,y值为1;接下来执行赋值语句y=5,因此y值变为5。

你可能感兴趣的试题

1

A.9 8 7 6 3 2   
B.2 3 6 7 8 9   
C.9 8 7 6 3
D.2 3 6 7 8
2
A.n As Integer    j As Integer
B.n As Integer    Static j As Integer
C.ByVal n As Integer  J As Integer
D.ByVal n As Integer  Static j As Integer
3
A.a乘以n的乘积   
B.a加n的利
C.a减n的差   
D.a除以n的商(不含小数部分)
找试题 · 找答案 · 找资料 在线模考