
15 Dec
2004
15 Dec
'04
4:25 a.m.
On Dec 14, 2004, at 9:56 PM, Cromwell Enage wrote:
To that end, I'm trying to write a function that gives users a path to the end vertex (11) from any other vertex in the maze graph. Unfortunately, this function currently works properly only when given the start vertex (0).
I think you want to use breadth_first_search on a reverse_graph, starting from the end vertex. It'll handle cycles and will compute the shortest paths automagically. Of course, you'll need to change that "directedS" to "bidirectionalS" in your graph type. Doug