unique(L)
The output list maintains the order of elements in L.
|
Another way to list the unique elements of L is by creating a set from L and then listing its elements. This may be slightly faster than unique, but forgets the ordering of L.
|
To count occurrences of each element, use tally. To create a sorted list, see sort. For an overview of lists and sequences, see lists and sequences.
The object unique is a method function with a single argument.
The source of this document is in /build/reproducible-path/macaulay2-1.25.05+ds/M2/Macaulay2/packages/Macaulay2Doc/functions/unique-doc.m2:42:0.