单项选择题

下列程序执行后,变量a的值为______。
dim a, b, c, d as single
a=100
b=20
c=1000
if b>a then
d=a: a=b: b=d
end if
if c>a then
d=a: a=c: c: d
end if
if c>b then
d=b: b=c: c=d
end if

A.0
B.1000
C.20
D.100
<上一题 目录 下一题>
热门 试题

单项选择题
有如下函数过程: Function lj(x As Integer) As Long Dim s As Long Dim i As Integer s=0 For i = 1 To x s=s+ i Next i 1j= s End Function在窗体上添加一个命令按钮,名为Command1, 编写事件过程调用该函数: Private Sub Command1 Click() Dim i As Integer Dim sum As Long For i = 1 To 5 sum = sum + 1j(i) Next i Print sum End Sub
A.25
B.35
C.45
D.55
单项选择题
单击命令按钮时,下列程序代码的执行结果为______。 Private Sub Proe1 (n As Integer,ByVa1 m As Integer) n=n Mod 10 m=m 10 End Sub Private Sub Command1_Click() Dim x As Integer Dim y As Integer x= 12 y = 34 Call Proe1 (x, y) Print x; y End Sub
A.12 34
B.2 34
C.2 3
D.12 3
相关试题
  • 执行以下程序段后,整型变量C的值为___...
  • 在窗体上添加如下命令按纽,然后编写如下事...