题型:综合题 题类:常考题 难易度:困难
浙江省温州市六校协作体2018届高三上学期信息技术期末联考试卷
Dim n As Integer
Dim a(1 To 100)As Integer
Private Sub Command1_Click() ‘生成n个有序数,显示在List1中
‘代码略
End Sub
Private Sub Command2_Click()
Dim t As Integer
Dim i As Integer
Dim j As Integer
Dim temp As Integer
t=Val(Text2.Text)
For i= To n ‘(1)
temp=a(i)
For j=i To i+1-t Step-1
a(j)=a(j-1)
Next j
=temp ‘(2)
Next i
For i=1 To n
List2.AddItem Str(a(i))
Next i
End Sub
试题篮