Navigation
Synopsis Remove multiple occurrences of elements in a list. The first occurrence remains.
Function list[&T] dup(list[&T] lst)
Usage import List;
Examples
rascal>import List;
ok
rascal>dup([3, 1, 5, 3, 1, 7, 1, 2]);
list[int]: [3,1,5,7,2]

Questions
Question [1].
The type of dup([false, false, true, false, false]) is

Question [2].
dup([false,true,true,true,false,true,true,true,true,false]) == 



Is this page unclear, or have you spotted an error? Please add a comment below and help us to improve it. For all other questions and remarks, visit ask.rascal-mpl.org.