Single Pass
Unlike Kosaraju's, Tarjan's identifies all SCCs in a single DFS traversal, making it slightly more efficient in practice.
Loading...
Loading Curriculum...
Loading Subject...
Loading Topic...
Loading Lesson...
Loading Lab...
A linear-time, single-pass DFS algorithm that identifies Strongly Connected Components. It maintains low-link values to detect the roots of cyclic components.
Unlike Kosaraju's, Tarjan's identifies all SCCs in a single DFS traversal, making it slightly more efficient in practice.
Each node tracks the smallest discovery time reachable from it. A node is an SCC root if its discovery time equals its low-link value.
Nodes are kept on a stack until their SCC is fully explored. When a root is identified, the stack is popped to extract the component.
Widely used in compiler optimization and dependency analysis to find circular references and interconnected modules.