试题 试卷
题型:单选题 题类:常考题 难易度:普通
浙江省温州市新力量联盟2018-2019学年高二下学期信息技术期末联考试卷
k=0:s=0
for i=2 to n
If a(i)>a(i-1) then
_______①_________
Else
k=0
End If
if _____②______ then s=s+1
next i
text1.text=str(s)
划线处的正确语句是( )
n = 0
m = 0
For i = 1 To 100
If Rnd > 0.5 Then
n = n + 1
m = m + 1
Next i
……
小金仔细分析该程序段后,发现其中缺少了( )
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)的值依次为( )
Do While i <= n
x = Int(Rnd() * 9) + 1 If x Mod 2 = 1 Then
a(i) = x Else
a(n) = x n = n - 1
i = i + 1 Loop
数组元素的初值均为 0,执行该程序段后,在下列选项中 a(1)至 a(5)各元素值不可能的是( )
PRIVATE SUB FORMCLICK
FOR I = 3 TO {#blank#}1{#/blank#}
F=0
FOR J= 2 TO I-1
IF {#blank#}2{#/blank#} THEN
F=1
EXIT FOR
END IF
NEXT J
IF F=0 THEN {#blank#}3{#/blank#}
{#blank#}4{#/blank#}
END SUB
x = ①
t = 0: s = ""
Do While x <> 0
t = ②
x = x \ 10
Loop
If ③ Then Then Then s = "是9的倍数" Else s = "不是9的倍数"
试题篮