First page Back Continue Last page Graphics
Traversing Graphs
It is often necessary to visit all the nodes in a graph. We therefore desire algorithms capable of traversing all the nodes of a graph.
Similar to pre-order, in-order traversals of BSTs
There are two distinct ways of thinking about graph traversal:
- Depth first
- Breadth first