duplicates ( set -- seq )
Factor handbook » The language » Collections » Sets » Operations on sets

Prev:all-unique? ( set -- ? )
Next:within ( seq set -- subseq )


Vocabulary
sets

Inputs
seta set


Outputs
seqa sequence


Word description
Outputs a sequence consisting of elements which occur more than once in set.

Examples
USING: sets prettyprint ; { 1 2 3 1 2 1 } duplicates .
{ 1 2 1 }


Definition

GENERIC: duplicates ( set -- seq )


Methods