Пример:
changeset = set([
frozenset([101,102]),
frozenset([103,104]),
frozenset([101,105]),
frozenset([106,107,109,103]),
frozenset([110,135]),
frozenset([111,136]), ])
На выходе должно получиться.
changeset = set([
frozenset([101,102,105]),
frozenset([103,104,106,107,109]),
frozenset([110,135]),
frozenset([111,136]), ])
frozenset([110, 104, 106, 135, 118])?
frozenset([101,102,105]),
frozenset([103,104,106,107,109,110,135,118]),
frozenset([111,136]),