单击命令按钮时,下列程序的执行结果是
Private Sub Command1_Click()
BT 4
End Sub
Private Sub BT(x As Integer)
x=x*2+1
If x<6 Then
Call BT(x)
End If
x=x*2
Print x;
End Sub
A.15
B.16
C.17
D.18
第1题:
单击命令按钮时,下列程序代码的执行结果为( )。 Private Function FirProc(x As Integer,y As Integer,z As Integer) FirProc=2*x+y+3*z End Funcfion Private Function SecProc(x As Integer,y As Integer,z As Integer) SecProc=FirProc(z,x,y)+x End Funcfion Private Sub Command1_Click() Dim a As Integer Dim b As Integer Dim c As Integer a=2 b=3 c=4 Printf SecProc(c,b,a) End Sub
A.21
B.19
C.17
D.34
第2题:
在窗体上画一个命令按钮,然后编写如下程序:
Dim x As Integer
Sub inc(a As Integer)
x=x+a
End Sub
Private Sub Command1_Click()
inc 2
inc 3
inc 4
Msgbox x;
End Sub
程序执行后,单击Command1命令按钮,消息框显示结果是【 】。
第3题:
单击命令按钮时,下列的执行结果为 Private Sub Command1_Click() Dim x As Integer,y As Integer x=86:y=29 Call Proc(x,y) Print x;y End Sub Public Sub Proc(n As Integer,ByVal m As Integer) n=n Mod 10 m=m Mod 10 End Sub
A.12 32
B.6 29
C.2 3
D.12 3
第4题:
执行下面程序,第一行输出结果是【 】,第二行输出结果是47。
Option Explicit
Private Sub Form_Click( )
Dim A As Integer
A=2
Call Sub1 (A) End Sub
Private Sub1 (x As Integer)
x=x*2+1
If x<10 Then
Call Sub1 (x)
End If
x=x*2+1
Print x
End Sub
第5题:
单击命令按钮时,下列程序的执行结果为 Private Sub Command1_Click() Dim x As Integer,y As Integer x=50:y=78 Call PPP(x,y) Print x;y End Sub Public Sub PPP(ByVal n As Integer,ByValm As Integer) n=n\10 m=m\10 End Sub
A.08
B.50 78
C.450
D.78 50
第6题:
单击命令按钮时,下列程序的执行结果是 Private Sub Book( x As Integer) x=x*2+1 If x<6 Then Call Book(x) End If x=x * 2 + 1 Print x; End Sub Private Sub Command2_Click( ) Book 2 End Sub
A.23 47
B.10 36
C.22 44
D.24 50
第7题:
执行下面这段程序后,单击命令按钮,窗体中输出结果是 ______。 Private Sub Command1_Click() a=1 : b=4 : c = 9 : d = 5 If a < b Then If c<d Then x=True Else If a<c Then x=False Else x=True End If End If End If Print Val(x) End Sub
A.True
B.False
C.0
D.1
第8题:
单击命令按钮时,下列程序代码的执行结果为______。 Private Function FirProc (x As Integer,y As Integer,z As Integer) FirProc=2*x+y+3*z End Function Private Function SecProc(x As Integer,y As Integer,z As Integer) SecProc=FirProc(z,x,y)+x End Function Private Sub Command1_Click() Dim a As Integer Dim b As Integer Dim C As Integer a=2 b = 3 c = 4 Print SecProc(c,b,A) End Sub
A. 21
B.19
C.17
D.34
第9题:
单击命令按钮,下列程序的执行结果是 Private Sub Blck (x As Integer) x = x * 2 + l If x <6 Then Call Blck(x) End If x = x * 2 + 1 Print x; End Sub Private Sub Commandl_Click() Blck 2 End Sub
A.23 47
B.10 36
C.22 44
D.24 50
第10题:
单击命令按钮时,下列程序的执行结果是 Private Sub Command1_Click Dim a As Integer, b As Integer, c As Integer a=3 b=4 c=5 Print SecProc(c, b, A. End Sub Function FirProc(x As Integer, y As Integer, z As Integer. FirProc=2x+y+3z End Function Function SecProc(x As Integer, y As Integer, z As Integer. SecProc=FirProc(z, x, y.+x End Function
A.20
B.22
C.28
D.30
第11题:
单击命令按钮时,下列程序的执行结果是 Private Sub Command1_Click() Dim a As Integer, b As Integer, c As Integer a=3:b :4:c =5 Print SecProc ( c, b,A)End Sub Function FirProc(x As Integer, y As Integer, z As Integer) FirProc:2 * x + y + 3 * z+2 End Function Function SecProc( x As Integer, y As Integer, z As Integer) SecProc = FirProc ( z, x, y) + x + 7 End Function
A.20
B.25
C.37
D.32
第12题:
执行下面程序,第一行输出结果是 [ ] ,第二行输出结果是 [ ] 。
Option Explicit
Private Sub Form_Click()
Dim A As Integer
A=2
Call Sub1(A)End Sub
Private Sub1(x As Integer)
x=x*2+1
If x<10 Then
Call Sub1(x)
End If
x=x*2+1
Print x
End Sub
第13题:
单击命令按钮时,下列程序的执行结果是
Private Sub Command1_Click()
Dima As Integer,b As Integer,c As Integer
a=3:b=4:c=5
Print SecProc(c,b,A)End Sub
Function FirProc(x As Integer,y As Integer,z As Integer)
FirProc=2*x+y+3*z+2
End Function
Function SecProc(x As Integer,y As Integer,z As Integer)
SecProc=FirProc(z,x,y) +x+7
End Function
A.20
B.25
C.37
D.32
第14题:
单击命令按钮时,下列程序的执行结果为 Private Sub Command1_Click() Dim a As Integer,b As Integer,c As Integer a=2:b=3:C=4 Print P2(c,b,A)End Sub Private Function P1(x As Integer,y As Integer,z As Integer) P1=2 * X + y + 3 * z End Function Private Function P2(x As Integer,y As Integer,z As Integer) P2=P1(z,x,y) + X End Function
A.21
B.19
C.17
D.34
第15题:
单击按钮时,以下程序运行后的输出结果是 Private Sub proc1(x As Integer,y As Integer,z As Integer) x=3*z y=2*z z=x+y End Sub Private Sub Command1_Click() Dim x As Integer,y As Integer,Z As Integer x=1:y=2:z=3 Call proc1(x,x,z) Print x;x;z Call proc1(x,y,y) Print x;y;y End Sub
A.6 6 12 `
B.9 5 10 6101051010
C.9 6 12
D.9 10 10 910155410
第16题:
单击命令按钮时,下列程序的执行结果是 Private Sub Command1_Click() BT 4 End Sub Private Sub BT(x As Integer) x=x*2+1 If x<6 Then Call BT(x) End If x=x*2 Print x; End Sub
A.15
B.16
C.17
D.18
第17题:
单击命令按钮时,下列程序的执行结果是
Private Sub Command1_Click()
BT 4
End Sub
Private Sub BT(x As Integer)
x=x*2 + 1
If x < 6 Then
Call BT(x)
End If
x=x 2
Print x;
End Sub
A.15
B.16
C.17
D.18
第18题:
在窗体上画一个命令按钮,名称为Command1。然后编写如下程序: Private Sub Command1_Click() Dim a As Integer,b As Integer,c As Integer If a=0 Then x=x-1 Else If b<>0 Then End If End If If c<>0 Then x=3 Else x=4 End If Print x End Sub 程序运行后,单击命令按钮,其输出结果为 ______。
A.34
B.4
C.35
D.3
第19题:
单击命令按钮执行下列程序,其输出结果是( )。 Private Sub Command1_Click() Dim a As Integer, b As Integer, c As Integer a=3 b=4 c=5 Print SecProc(c,b,A)End Sub Function FirProc(x As Integer, y As Integer, z As Integer) FirProc=2*x+y+3*Z End Function Function SecProc(x As Integer,y As Integer, z As Integer) SecProc=FirProc(z,x,y)+x End Function
A.20
B.22
C.28
D.30
第20题:
在窗体中添加一个名称为Command1的命令按钮,然后编写如下程序: Public x As Integer Private Sub Command1_Click() x=10 Call s1 Call s2 MsgBox x End Sub Private Sub sl() x=x+20 End Sub Private Sub s2() Dim x As Integer x=x+20 End Sub 窗体打开运行后,单击命令按钮,则消息框的输出结果为( )。
A.10
B.30
C.40
D.50
第21题:
单击命令按钮时,下列程序的执行结果为 Private Sub Command1_Click( ) Dim x As Integer,y As Integer x=50:y=78 Call PPP(x,y) Print x;y End Sub Public Sub PPP(ByVM n As Integer,ByVal m As Integer) n=n\l0 m=m\l0 End Sub
A.08
B.50 78
C.450
D.78 50
第22题:
在窗体上画一个命令按钮,名称为Command1。然后编写如下程序: Private Sub Command1_Click() Dim a As Integer,b As Integer,c As Integer If a=0 Then x=x-1 Else If b<>0 Then End If End If If c<>0 Then x=3 Else x=4 End If Print x End Sub程序运行后,如果单击命令按钮,则在窗体上显示的内容是( )。
A.34
B.4
C.35
D.3
第23题:
单击命令按钮时,下列程序的执行结果是 Private Sub Commandl_Click( ) BT 4 End Sub PriVate Sub BT(x As Integer) X=X * 2 + 1 If x <6 Then Call BT(x) End If X=x * 2 Print x; End Sub
A.15
B.16
C.17
D.18