请认真阅读并分析下面Visual Basic程序代码,按要求完成题目。
Dim a(1 To 6) As Integer
Dim n, i, j, k As Integer
Private Sub Command1_Click()
For i =" 1" To n - 1
For j = (1) To n
If a(i) < a(j) Then
k = a(i): (2) : a(j) = k
End If
Next j
Next i
For i =" 1" To n
list2.AddItem Str(a(i))
Next I
End Sub
Private Sub Text1_KeyPress(KeyAscii As Integer)
If KeyAscii =" 13" Then
n =" n" + 1
a(n) = Val( (3) )
List1.AddItem Str(a(n))
Text1.Text = "": Text1.SetFocus
End If
End Sub
①程序中出现了text和list两种控件,其中list控件的中文名称是列表框,text控件的中文名称是 。
(2)在上述程序段中3处带序号的空白地方补充恰当的语句,完善程序。
相关知识点
推荐试卷