Answer: Prim's algorithm

Question: Prim's algorithm for minimum spanning trees only applies when the edges are undirected. Where does the proof fall through when the edges are directed?

Answer: The proof assumes that we have a spanning tree better than what Prim's algorithm gives. It takes an edge in Prim's output and adds it to the spanning tree to get a cycle. If the graph is directed, adding the edge may not create a cycle.


Answer / Graphs / Review questions / 15-211 A, B