Question: Give an example of a directed graph G = (V, E), a source vertex s V, and a set of tree edges E

Give an example of a directed graph G = (V, E), a source vertex s ¬ V, and a set of tree edges E π ¬ E such that for each vertex v ¬ V, the unique path in the graph (V, E π) from s to v is a shortest path in G, yet the set of edges E π cannot be produced by running BFS on G, no matter how the vertices are ordered in each adjacency list.

Step by Step Solution

3.44 Rating (180 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

The edges in E are shaded in the following graph To see that E c... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Document Format (1 attachment)

Word file Icon

C-S-A (172).docx

120 KBs Word File

Students Have Also Explored These Related Algorithms Questions!