• 2022-06-12
    下面程序执行时,输出的结果是______。 Private Sub Form_Click() Dim i As Integer,j As Integer i=10 Do i=i+j For j=10 To i Step-3 i=i+j Next j Loop While i<50 Print i;j End Sub
    A: 50 10
    B: 50 9
    C: 57 10
    D: 57 9
  • C

    内容

    • 0

      下列程序: Option Base 1 Private Sub Form_Click() Dim a(5,5) For i = 1 To 5 For j = 1 To 5 k = k + 1 a (i,j)= k Next j Next i For i = 1 To 5 s = s + a (i,i) Next i Print s End Sub 运行时的输出结果是( )。

    • 1

      运行以下程序,单击命令按钮后在窗体上输出内容_________。Private Sub Command1_Click()Dim a() As IntegerDim i As Integer, j As IntegerReDim a(3, 4)For i = 1 To 3For j = 1 To 4a(i, j) = i* 10 + jNext jNext iReDim a(4, 5)Print a(2, 3)End Sub

    • 2

      在窗体上画一个命令按钮(其Name属性为Command1),然后编写如下代码: Option Base 1 Private Sub Command1_Click() Dim a(4,4) For i=1 To 4 For j=1 To 4 a(i,j)=(i-1)*3+j Next j Next i For i=3 To 4 For j=3 To 4 Print a(j,i); Next j Next i End Sub 程序运行后,单击命令按钮,其输出结果为 ______ 。 A.6 9 7 10 B.7 10 8 11 C.8 11 9 12 D.9 12 10 13

    • 3

      下列程序段的执行结果为________。 Dim M(10), N(10) i= 4 For j = 1 To 7 M(j) = j N(i) = 2 * i + j Next j Print N(i); M(i)

    • 4

      在窗体上画一个名称为Command1的命令按钮 ,并编写如下程序:Option Base 1Private Sub Command1_Click() Dim a(4,4) For i=1 To 4 For j=1 To 4 a(i,j)=(i-1)*3+j Next j Next i For i=3 To 4 For j=3 To 4 Print a(j,i); Next j Print Next iEnd Sub运行程序,单击命令按钮,则输出结果为______。 A: 6 9 7 10 B: 7 10 8 11 C: 8 11 9 12 D: 9 12 10 13