Strongly Connected Components Tarjan's Algorithm https://en.wikipedia.org/wiki/Tarjan%27s_strongly_connected_components_algorithm Kosaraju's Algorithm https://en.wikipedia.org/wiki/Kosaraju%27s_algorithm