Disjoint Set data structure

Home > Computer Science > Algorithms and data structures > Disjoint Set Union > Disjoint Set data structure

This is a data structure used to maintain a collection of disjoint sets. It supports operations like makeSet, union and find, which are used to form new sets, merge existing sets and determine the set membership of an element respectively.