useful graph algorithms (dijkstra, bellman ford, scc) for later use