试题 试卷
题型:单选题 题类:常考题 难易度:普通
浙江省金华市江南中学2020届高三信息技术网课2月22日第二周测试卷
Randomize
For i= 1 To 6
a(i) =Int(Rnd*20) + 1
If a(i) Mod 2=i Mod 2 Then
a(i)=a(i)-1
Else
a(i)=a(i)+2
End If
Next i
执行该程序段后,a(1)~a(6)各元素可能的是( )
s = 0: i = 1
n = Val(Text1.Text)
Do While i < n
s = s + i
i = i + 1
Label1.Caption = Str(s)
For i = 5 To 4 Step -1
k = i
For j = 6 - i To 1 Step -1
If a(j) < a(k) Then k = j
Next j
If i <> k Then
t = a(i): a(i) = a(k): a(k) = t
数组元素a(1)到a(5)的值依次为“41,66,70,83,31”,经过该程序段“加工”后,数组元素a(1)到a(5)的值依次为( )
s = 0
For i = 1 To 20 Step 2
If s < 15 Then
以上程序执行结束后,变量s和i的值分别为( )
s=0
For k=1 To 5
s=s * k
Next k
Print s
试题篮