equal
deleted
inserted
replaced
118 std::cout << g.id(v) << "<-"; |
118 std::cout << g.id(v) << "<-"; |
119 } |
119 } |
120 std::cout << g.id(s) << std::endl; |
120 std::cout << g.id(s) << std::endl; |
121 \endcode |
121 \endcode |
122 |
122 |
123 See the whole program in \file dijkstra_demo.cc. |
123 See the whole program in \ref dijkstra_demo.cc. |
124 |
124 |
125 The first part of the code is self-explanatory: we build the graph and set the |
125 The first part of the code is self-explanatory: we build the graph and set the |
126 length values of the edges. Then we instantiate a member of the Dijkstra class |
126 length values of the edges. Then we instantiate a member of the Dijkstra class |
127 and run the Dijkstra algorithm from node \c s. After this we read some of the |
127 and run the Dijkstra algorithm from node \c s. After this we read some of the |
128 results. |
128 results. |