设有命令按钮Command1的单击事件过程,代码如下: Private Sub Command1 Click() Dim a(3,3)As Integer For i=1 To 3 For j=1 To 3 a(i,j)=i*j+i Next j Next i Sum=0 For i=1 To 3 Sum=Sum+a(i,4-i) Next i Print Sum End Sub 运行程序,单击命令按钮,输出结果是______。A.20B.7C.16D.17
设有命令按钮Command1的单击事件过程,代码如下: Private Sub Command1 Click() Dim a(3,3)As Integer For i=1 To 3 For j=1 To 3 a(i,j)=i*j+i Next j Next i Sum=0 For i=1 To 3 Sum=Sum+a(i,4-i) Next i Print Sum End Sub 运行程序,单击命令按钮,输出结果是______。
A.20
B.7
C.16
D.17
相关考题:
设有命令按钮Command1的单击事件过程,代码如下:Private Sub Command1_Click()Dim a(3,3)As IntegerFor i=1 To 3For j=1 To 3a(i,j)=i*j+iNext jNext iSum=0For i=1 To 3Sum=Sum+a(i,4-i)Next iPrint SumEnd Sub运行程序,单击命令按钮,输出结果是( )。A.20B.7C.16D.17
( 22 )命令按钮 Command1 的单击事件过程的代码如下:Private Sub Command1_Click( )Dim a(3 , 3)As IntegerFor i=1 To 3For j=1 To 3a(i , j)=i*j+iNext jNext iSum=0For i=1 To 3Sum=Sum+a(i , 4-i)Next iPrint SumEnd Sub运行程序,单击命令按钮,输出结果是( )。A ) 20B ) 7C ) 16D ) 17
设有命令按钮Command1的单击事件过程,代码如下:Private Sub Command1_Click()Dim a As IntegerFor i=1 To 30a(i)=iNextFor Each arrItem 【 】aIf arrItem Mod 7=0 Then Print arrItem;If arritem90 Then Exit ForNextEnd Sub请填空。
设有命令按钮Command1的单击事件过程,代码如下,请填空。Private Sub Command1_Click()Dim a(30) As IntegerFor i=1 To 30a(i) =iNextFor Each arrItem______aIf arrItem Mod 7=0 Then Print arrItem;If arrItem>90 Then Exit ForNextEnd Sub
设有一个命令按钮Command1的事件过程以及一个函数过程。程序如下: Private Sub Command1 Click( ) Static x A S Integer x=f(x+5) Cls Print X End Sub Private Function f(x As Integer)As Integer f=x+x End Function 连续单击命令按钮3次,第3次单击命令按钮后,窗体显示的计算结果是( )。A.10B.30C.60D.70
(6)在窗体上有1个名称为Command 1的命令按钮,并有如下事件过程和函数过程:Private Sub Command 1_Click()Dim p As Integerp=m(1)+m(2)+m(3)Print pEnd SubPrivate Function m(n As Integer) As IntegerStatic s As IntegerFor k=1 To ns=s+1Nextm=sEnd Function运行程序,单击命令按钮Command 1的输出结果为【6】。
在窗体中有一个名为Command1的命令按钮,Click事件的代码如下: Private Sub Command1_Click() f = 0 For n = 1 To 10 Step 2 f = f + n Next n Me!Lb1.Caption = f End Sub 单击命令按钮后,标签显示的结果是()。