Element keys are values identifying elements. They are used as array keys and are subject to the same rules as array keys, for example, integer 100 and string "100" are considered equal.
Syntax: distinct (other)
Produces the set difference of two sequences using values as element keys.
Syntax: distinct (other, keySelector {(v, k) ==> value})
Produces the set difference of two sequences using values produced by keySelector as element keys.
public except ( array | Iterator | IteratorAggregate | |
||
$other | array | Iterator | IteratorAggregate | |
A sequence whose elements that also occur in the source sequence will cause those elements to be removed from the returned sequence. |
$keySelector | callable | null | {(v, k) ==> key} A function to extract the element key from each element. Default: value. |
return | A sequence that contains the set difference of the elements of two sequences. |