Set Intersection
rascal-0.40.17
Synopsis
Intersection of two sets.
Syntax
Exp₁ & Exp₂
Types
Exp₁ | Exp₂ | Exp₁ & Exp₂ |
---|---|---|
set[T₁] | set[T₂] | set[lub(T₁,T₂)] |
Description
Returns the intersection of the two set values of Exp₁ and Exp₂. The intersection consists of the common elements of both sets.
Examples
rascal>{1, 2, 3, 4, 5} & {4, 5, 6};
set[int]: {5,4}