Private Sub Form_Click() Dim a(), i%, j%, n%, s% a() = Array(1, 24, 23, 53, 56) n = UBound(a) For i = 0 To n - 1 For j = i + 1 To n If a(i) > a(j) Then s = a(i) a(i) = a(j) a(j) = s Next j Next i For i = LBound(a) To UBound(a) Print a(i); Next End Sub