Dim a(15) As Integer
Dim str As String
str = ""
Dim temp As Integer
For i = 1 To 15
a(i) = Int(Rnd() * 90) + 10
Next
For i = 1 To 15
For j = 1 To 15 - i
If a(j) < a(j + 1) Then
temp = a(j + 1)
a(j + 1) = a(j)
a(j) = temp
End If
Next j
Next i
For i = 1 To 15
str = str & a(i) & " "
Next
Label1.caption = str
15个数从大到小排列
最新推荐文章于 2023-12-26 21:29:40 发布