15 lines
263 B
Text
15 lines
263 B
Text
procedure main(args)
|
|
every write(!noDups(args))
|
|
end
|
|
|
|
procedure noDups(L)
|
|
every put(newL := [], notDup(set(),!L))
|
|
return newL
|
|
end
|
|
|
|
procedure notDup(cache, a)
|
|
if not member(cache, a) then {
|
|
insert(cache, a)
|
|
return a
|
|
}
|
|
end
|