Neocortex 🧠

Search

Search IconIcon to open search

DFS and Spanning Trees

Last updated Jan 24, 2022 Edit Source

When running Depth-First Search on a graph, a spanning tree that is rooted at the algorithm’s start node, $s$ is formed. This tree is guranteed to be spanning the whole connected component that $s$ is in.


Interactive Graph