Dijkstra's shortest path algorithm
Kruskal's minimum spanning tree using a Disjoint-set forest implementation