MST

Kruskal and Prim; union-find.