[prev] 71 [next]

Exercise #11: Breadth-first Traversal

Show the state of the queue and the BFS order in which we visit vertices in this graph when searching for a path from 0 to 6:

[Diagram:Pic/traversal.png]

Consider neighbours in ascending order