( 27 )下面程序执行时,在窗体上显示的是Private Sub Command1_Click()Dim a(10)For k = 1 To 10a(k) = 11 – kNext kPrint a(a(3)\a(7) Mod a(5))End SubA ) 3B ) 5C ) 7D )9
( 27 )下面程序执行时,在窗体上显示的是
Private Sub Command1_Click()
Dim a(10)
For k = 1 To 10
a(k) = 11 – k
Next k
Print a(a(3)\a(7) Mod a(5))
End Sub
A ) 3
B ) 5
C ) 7
D )9
相关考题:
在窗体上面—个名称为Command1的命令按钮,并编写以下程序: Private Sub Command1_Click() Print fun("ABCDEFG") End Sub Function fun(st As String)As String stlen=Len(st) tempe="" For k=1 To stlen/2 temp=temp+Mid(st,k,1)+Mid(st,stlen-k+1,1) Next k fun=temp End Function 程序运行时,单击命令按钮,则在窗体上显示的是______。A.ABCDEFGB.AGBFCEC.GFEDCBAD.AGBFCED
( 31 )在窗体上画 1 一个名称为 Command1 的命令按钮,并编写以下程序Private Sub Command1_Click ()Print fun ( “ ABCDEFG ” )End SubFunction fun ( st As String ) As Stringstlen=Len ( st )temp= ””For ktemp=temp=Mid(st,k,l)+Mid(st,stlen-k+1 , 1)Next kfun=tempEnd Function程序运行时,单击命令按钮,则窗体上显示的是( )A ) ABCDEFGB ) AGBFCEC ) GFEDCBAD ) AGBFCED
在窗体上画一个名称为Command1的命令按钮,然后编写如下程序:Dim k As IntegerPrivate Sub form_ Load() k = 15End SubPrivate Sub Command1_ Click()Static b As IntegerDim k As Integer k= k +1 b = b+1 Print k, bEnd Sub程序运行时,两次单击命令按钮Command1后,在窗体上显示的第二行是______。A.1 1B.1 2C.2 1D.2 2
在一个窗体上添加一命令按钮控件,名为Command1,事件过程如下,则执行结果是( )。Option Base 1Private Sub Command1_Click()Dim a(5) As IntegerDim k As IntegerDim total As Integera(1)=2a(2)=5a(3)=4a(4)=10a(5)=6For k=1 To 5total=total+a(k)Next kPrint totalEnd SubA.10B.15C.27D.35
下面程序执行时,在窗体上显示的是。Private Sub Commandl_ClickDim a(10)For k=1 TO 10a(k)=11-kNext kPrinta(a(3)\a(7)Mod a(5))End SubA.3B.5C.7D.9
在窗体上画一个名称为Command1的命令按钮,然后编写如下程序 _______。 Dim k As Integer Private Sub Form_Load() k=5 End Sub Private Sub Command Click() Static b As Integer b = b + k k=k+1 Print k,b End Sub 程序运行时,两次单击命令按钮Command1后,在窗体上显示的第二行是 _______。A.7 11B.5 11C.76D.2 1
在窗体上画1个名称为Command1的命令按钮,然后编写下列程序:Private Sub Command1_Click( )Print fun(ABCDEFG)End SubFunction fun(st As String)As stringstlen=Len(st)temp=For k=1 To stlen/2temp=temp+Mid(st,k,1)+Mid(st,stlen-k+1,1)Next kfun=tempEnd Function程序运行时,单击命令按钮,则在窗体上显示的是( )。A.ABCDEFGB.AGBFCEC.GFEDCBAD.AGBFCED
下面程序运行时,单击窗体后,窗体上显示的结果是( )。 Private Sub Form_Click Dim I As Integer Dim sum As Long Dim t1 As Long t1=1:sum=0 For 1=1 To 3 t1=t1*I sum=sum+t1 Next I Print sum End SubA.3B.9C.5D.6