主题:数组逆向排序
数组逆向排序,补充程序。
Private Sub Form_Click()
Dim x(5) As Integer
x(1) = 3: x(2) = 9: x(3) = 7: x(4) = 4: x(5) = 2
For i = 1 To 4
For j = i + 1 To 5
If_____________ Then t = x(i):_____________:_______________
Next j, i
For k = 1 To 5
Form1.Print "x("; k; ")="; _____________
Next k
End Sub
Private Sub Form_Click()
Dim x(5) As Integer
x(1) = 3: x(2) = 9: x(3) = 7: x(4) = 4: x(5) = 2
For i = 1 To 4
For j = i + 1 To 5
If_____________ Then t = x(i):_____________:_______________
Next j, i
For k = 1 To 5
Form1.Print "x("; k; ")="; _____________
Next k
End Sub