Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
|
|
@ -0,0 +1,16 @@
|
|||
Dim temp, count As Integer
|
||||
Dim isDirty As Boolean
|
||||
count = Ubound(list) // count the array size
|
||||
|
||||
// loop through until we don't move any numbers... this means we are sorted
|
||||
Do
|
||||
isDirty = False // we haven't touched anything yet
|
||||
For i As Integer = 1 To count - 1 // loop through all the numbers
|
||||
If list(i) > list(i + 1) Then // if the right number is smaller then the left.. swap
|
||||
temp = list(i + 1)
|
||||
list(i + 1) = list(i)
|
||||
list(i) = temp
|
||||
isDirty = True // we touched the data so mark it as dirty
|
||||
End
|
||||
Next
|
||||
Loop Until isDirty = False // if we made it without touching the data then we are done
|
||||
Loading…
Add table
Add a link
Reference in a new issue