export function union(...sets: Iterable[]): Set { const unionSet = new Set() for (const set of sets) { for (const element of set) { unionSet.add(element) } } return unionSet }