Last list item: Difference between revisions
Content deleted Content added
→{{header|ALGOL 68}}: Re-added sorted version, with the correct positioning of the new element (was wrong due to an error in translation) |
m Algol 68 →With sorting |
||
Line 12: | Line 12: | ||
===With sorting=== |
===With sorting=== |
||
{{trans|Wren}} |
{{trans|Wren}} |
||
⚫ | |||
<lang algol68> |
|||
⚫ | |||
# of the two smallest elements and removing them # |
# of the two smallest elements and removing them # |
||
# Quicksorts in-place the array of integers a, from lb to ub # |
# Quicksorts in-place the array of integers a, from lb to ub # |
||
Line 55: | Line 54: | ||
OD; |
OD; |
||
print( ( "Last item is ", whole( a[ 1 ], 0 ), ".", newline ) ) |
print( ( "Last item is ", whole( a[ 1 ], 0 ), ".", newline ) ) |
||
END |
END</lang> |
||
</lang> |
|||
{{out}} |
{{out}} |
||
<pre> |
<pre> |