all tasks
This commit is contained in:
parent
b83f433714
commit
68f8f3e56b
14735 changed files with 178959 additions and 0 deletions
|
|
@ -0,0 +1,15 @@
|
|||
Procedure bubbleSort(Array a(1))
|
||||
Protected i, itemCount, hasChanged
|
||||
|
||||
itemCount = ArraySize(a())
|
||||
Repeat
|
||||
hasChanged = #False
|
||||
itemCount - 1
|
||||
For i = 0 To itemCount
|
||||
If a(i) > a(i + 1)
|
||||
Swap a(i), a(i + 1)
|
||||
hasChanged = #True
|
||||
EndIf
|
||||
Next
|
||||
Until hasChanged = #False
|
||||
EndProcedure
|
||||
Loading…
Add table
Add a link
Reference in a new issue