Add a DisjointSet implementation in the util package.