单项选择题

以下程序输出1到1000之间所有的偶数之和,请补充完该程序。 Private Sub Cotmand1_Click() Dim x As Double For i=0 To 1000 If______ Then x=x+ i End If Next i Print x End Sub

A.i Mod 2= 0
B.x mod 2=0
C.I mod 2<>0
D.x mod 2<>0
<上一题 目录 下一题>
热门 试题

单项选择题
以下程序段的执行结果是 ______。 Dim A(3, 3) For m = 1 To 3 For n = 1 To 3 If n = m Or n = 3 - m + 1 Then A(m, n) =m + n Else A(m, n) = 0 End If Next n Next m For m = 1 To 3 For n = 1 To 3 Print A(m, n); Next n Print Next m
A.1 1 1 1 1 1 1 1 1
B.2 0 4 0 4 0 4 0 6
C.0 0 0 0 0 0 0 0 0
D.1 0 1 0 1 0 1 0 1
单项选择题
有如下函数:Private Function firstfunc(x As Integer, y As Integer) As Integer Dim n As Integer Do While n <= 4 x=x +y n=-+1 Loop firstfunc = x End Function调用该函数的事件过程如下:Private Sub Command1_lick() Dim x As Integer Dim y As Integer Dim n As Integer Dim z As Integer x=1 y=1 For n = 1 To 3 z = firstfunc(x, y) Next n Print z End Sub该事件过程的执行结果是 ______。
A.1
B.3
C.16
D.9
相关试题
  • 下列程序的运行机结果是 【15】 。Priv...
  • 以下程序用于求s=1+(1+2)+(1+...
  • 在传统集合运算中,假定有关系R和s,运算结...
  • 下列程序的作用是求所有小于或等于30的自...
  • 有如下程序:Private Sub Command1_Cli...