Why union find is such a cool algorithm
One of my favorite algorithms in graph theory is Union Find. It is a beautiful algorithm for tracking disjoint sets. A disjoint set is a group of nodes in an undirected graph that are all connected to each other through some path, but disconnected from any node outside the set.