单选题
Access
题号 #5100563
下列VBA程序段的执行结果是( )。
A=75:K=0
IfA<90 then K=K+1
IfA>80 then K=K+1
IfA<70 then K=K+1
IfA>60 then K=K+1
MsgBox K
参考答案
A
答案解析
程序从上往下顺序执行,第1个If语句条件成立执行,K=1;执行第2个If语句,条件不成立;执行第3个If语句,条件不成立;执行第4个If语句,条件成立,k=2,故最终输出K的值为2。故本题选择A选项。
你可能感兴趣的试题
A.M A STUDENT!
B.STUDENT!
C.m a student!
D.student!
A.result(x)="偶数"
B.result(x)
C.result(x)= "奇数"
D.Not result(x)