setUnion

setUnion(set1, set2)

Try it yourself:


Combine set members with setUnion

setUnion(A, B) returns every distinct member found in either set. It is the natural operation for merging tags, permissions, or candidate lists.

Example

The union of {1,2} and {2,3} is {1,2,3}. Use setIntersect for only common members and setSymDifference for only non-shared members.

Input notes

Union removes duplicate membership. Use concat when duplicates and source order must remain, and setSize to count the merged distinct result.

All functions