DSA Lab 7 Fall 2009, 10/14/09

This lab is about graphs, BFS and algorithms.
  1. For the graph shown Petersen graph, starting from any vertex (the end vertices of the paths will be distinct), display a DFS spanning tree (these are all examples of subgraphs of the given graph) and a BFS spanning tree. Here is a Problem which models Petersen's graph.
  2. The BFS procedure is already described in the above code. Modify it to print the BFS spanning tree.
  3. Modify the code to make it (shortest path algorithm) work on a weighted graph (i.e., edges have weights) You can use Priority queue from STL.