Common sorted list: Difference between revisions

Content added Content deleted
(add RPL)
(Added Easylang)
Line 453: Line 453:
;; => (1 3 4 5 7 8 9)
;; => (1 3 4 5 7 8 9)
</syntaxhighlight>
</syntaxhighlight>

=={{header|EasyLang}}==
<syntaxhighlight>
nums[][] = [ [ 2 5 1 3 8 9 4 6 ] [ 3 5 6 2 9 8 4 ] [ 1 3 7 6 9 ] ]
#
proc sort . d[] .
for i = 1 to len d[] - 1
for j = i + 1 to len d[]
if d[j] < d[i]
swap d[j] d[i]
.
.
.
.
#
for l to len nums[][]
for e in nums[l][]
h[] &= e
.
.
sort h[]
for e in h[]
if e <> last or len r[] = 0
r[] &= e
last = e
.
.
print r[]
</syntaxhighlight>



=={{header|Excel}}==
=={{header|Excel}}==