[单选题]

单击一次命令按钮后,下列程序的执行结果为

Private Sub Command1_Click()

D.im m As Integer,I As Integer,x(10) As Integer

F.or I=0 To 4:x(I)=I+1:Next I

F.or I=1 TO 2:Call Prioc(x):Next I

F.or I=0 TO 3:Print x(I);:Next I

E.nd Sub

Private Sub Prioc(a()As Integer)

Static I As Integer

D.o

a(I)=a(I)+a(I+1)

I=I+1

Loop While I<2

E.nd Sub

A.3 4 7 5

B.3 5 7 4

C.1 2 3 4

D.1 2 3 5

参考答案与解析:

相关试题

单击一次命令按钮后,下列程序的执行结果是 Private Sub Command

[单选题]单击一次命令按钮后,下列程序的执行结果是 Private Sub Command1_Click() s=P(1) +P(2) +P(3) +P(4) Print s End Sub Public Function P(N As Integer) Static Sum For i=1 To N Sum=Sum+i Next i P=Sum End FunctionA.15B.25C.35D.45

  • 查看答案
  • 单击命令按钮时,下列程序的执行结果为()。Private Sub Command

    [单选题]单击命令按钮时,下列程序的执行结果为( )。 Private Sub Commandl_Click() Dimx As Integer,y As Integer x=12: y=32 CallPCS(x,y) PrintX;y End Sub PubUc Sub PCS(ByValn As Integer,ByValm As Integer) n=nMod 10 m=mMod 10 End SubA.1232B.232C.23D.123

  • 查看答案
  • 单击命令按钮时,下列程序的执行结果为 Private Sub Command1_

    [单选题]单击命令按钮时,下列程序的执行结果为Private Sub Command1_Click()D.im x As Integer, y As Integerx=12: y=32C.all PCS(x, y)Print x; yE.nd SubPublic Sub PCS(ByVal n As Integer, ByVal m As Integer)n=n Mod 10m=m Mod 10E.nd SubA.12 32B.2 32C.2 3D.12 3

  • 查看答案
  • 单击命令按钮时,下列程序的执行结果为 Private Sub Command1_

    [单选题]单击命令按钮时,下列程序的执行结果为 Private Sub Command1_Click( ) Dim x As Integer,y As Integer x=12:y=32 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 SubA.12 32B.2 32C.2 3D.12 3

  • 查看答案
  • 单击命令按钮时,下列程序代码的执行结果为 Private Sub Command

    [单选题]单击命令按钮时,下列程序代码的执行结果为 Private Sub Command1_Click( ) Print MyFunc(24,18) End Sub Public Function MyFunc(m As Integer,n As Integer)As Integer Do While m ◇ n Do While m>n:m=m—n:Loop DO While m<n:n=n-m:Loop Loop My Func=m End FunctionA.2B.4C.6D.8

  • 查看答案
  • 单击命令按钮时,下列程序的执行结果为 Private Sub Command1_

    [单选题]单击命令按钮时,下列程序的执行结果为 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 SubA.08B.50 78C.450D.78 50

  • 查看答案
  • 单击一次命令按钮后,下列程序的执行结果是()。Private Sub Comma

    [单选题]单击一次命令按钮后,下列程序的执行结果是( )。 Private Sub Commandl_Click() s=P(1)+P(2)+P(3)+P(4) Print s End Sub Public FunctionP(N As Integer) Static Sum Fori=1To N Sum=Sum+i Nexti P=Sum End FunctionA.15B.25C.35D.45

  • 查看答案
  • 单击一次命令按钮,下列程序代码的执行结果为()。Private Sub Comm

    [单选题]单击一次命令按钮,下列程序代码的执行结果为( )。 Private Sub Commandl_Click() Dima As Integer,b As Integer,CASInteger a=2:b=3:c=4 PrintP2(c,b,A) End Sub PrivateFunctionPl(X As Integer,y As Intege;z As Integer) P1=2*x+y+3*Z End Function PrivaA.21B.19C.17D.34

  • 查看答案
  • 单击命令按钮时,下列程序的执行结果为Private Sub Command1_c

    [单选题]单击命令按钮时,下列程序的执行结果为 Private Sub Command1_click() Dim X As Integer,Y As Integer x=12:y=32 Call PCS(x,y) Print x;y End Sub Public Sub PCS(ByVal n As Integer,ByVal m As Integer) n=n Mod 10 m=m Mod 10 End SubA.12 32B.2 32C.2 3D.12 3

  • 查看答案
  • 单击命令按钮时,下列程序的执行结果为Private Sub Command1_C

    [单选题]单击命令按钮时,下列程序的执行结果为 Private Sub Command1_Click( ) Dim x As Integer, y As Integer x=12:y=32 Call PCS(x, y) Print x; y End Sub Public Sub PCS( ByVal n As Integer, ByVal m As Integer) n = n Mod 10 m=m Mod 10 End SubA.12 32B.2 32C.2 3D.12 3

  • 查看答案
  • 单击一次命令按钮后,下列程序的执行结果为 Private Sub Command