1.bmp

 

語法領取處:

Dim aNum(1 To 5) As Integer

Private Sub Command1_Click()
n = UBound(aNum)
For i = n - 1 To 1 Step -1
For j = 1 To i
If aNum(j) > aNum(j + 1) Then
t = aNum(j)
aNum(j) = aNum(j + 1)
aNum(j + 1) = t
End If
Next j
Next i
For Each s In aNum
Label4.Caption = Label4.Caption & s & "     "
Next
End Sub

Private Sub Form_Load()
aNum(1) = 28: aNum(2) = 25: aNum(3) = 12: aNum(4) = 44: aNum(5) = 13
For i = 1 To UBound(aNum)
Label3.Caption = Label3.Caption & aNum(i) & "     "
Next i
End Sub


 

創作者介紹

小甫的窩

zj3y30915 發表在 痞客邦 PIXNET 留言(0) 人氣()