Sorting algorithms/Selection sort: Difference between revisions

Added 11l
(Added Arturo implementation)
(Added 11l)
Line 24:
*   Wikipedia:   [[https://en.wikipedia.org/wiki/Big_O_notation Big O notation]].
<br><br>
 
=={{header|11l}}==
{{trans|Python}}
 
<lang 11l>F selection_sort(&lst)
L(e) lst
V mn = min(L.index .< lst.len, key' x -> @lst[x])
(lst[L.index], lst[mn]) = (lst[mn], e)
 
V arr = [7, 6, 5, 9, 8, 4, 3, 1, 2, 0]
selection_sort(&arr)
print(arr)</lang>
 
{{out}}
<pre>
[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]
</pre>
 
=={{header|360 Assembly}}==
Line 93 ⟶ 110:
-31 0 1 2 2 4 45 58 65 69 74 82 82 83 88 89 99 104 112 782
</pre>
 
=={{header|AArch64 Assembly}}==
{{works with|as|Raspberry Pi 3B version Buster 64 bits}}
1,481

edits