I don't know if it's the most efficient way, but I'd do something like this:
Variables:
A (integer) = 0
B (integer) = 0
TemporaryStorage (real) = 0.0
ArrayLength = 10
General - For each integer A from 0 to (ArrayLength - 2) with increment 1, do (Actions)
Actions
General - For each integer B from (A + 1) to (ArrayLength - 1) with increment 1, do (Actions)
Actions
General - If (Conditions) then do (Actions) else do (Actions)
If
Array[A] > Array[B]
Then
Variable - Set TemporaryStorage = Array[B]
Variable - Set Array[B] = Array[A]
Variable - Set Array[A] = TemporaryStorage
Else
That will just compare each number to all the numbers after it, and if it finds one that's smaller then it'll trade places. I don't know if there's a way to get the length of an array automatically, so you'll have to adjust ArrayLength yourself to however long the array is.
I've just been reading about those sorting algorithms on Wikipedia. Turns out I invented off the top of my head a Selection Sort. Who'da thunk?
I don't know if it's the most efficient way, but I'd do something like this:
Variables:
A (integer) = 0
B (integer) = 0
TemporaryStorage (real) = 0.0
ArrayLength = 10
General - For each integer A from 0 to (ArrayLength - 2) with increment 1, do (Actions)
Actions
General - For each integer B from (A + 1) to (ArrayLength - 1) with increment 1, do (Actions)
Actions
General - If (Conditions) then do (Actions) else do (Actions)
If
Array[A] > Array[B]
Then
Variable - Set TemporaryStorage = Array[B]
Variable - Set Array[B] = Array[A]
Variable - Set Array[A] = TemporaryStorage
Else
That will just compare each number to all the numbers after it, and if it finds one that's smaller then it'll trade places. I don't know if there's a way to get the length of an array automatically, so you'll have to adjust ArrayLength yourself to however long the array is.