Unformatted text preview: i do if mark[w] = 0 then begin mark[w]=1; count=count1 e n d if count = 1 then print(‘YES’) else print(‘NO’) 8.[10] Sort the below graph topologically. Illustrate all major steps. A solution at the end 9.[40] In the graph from Question 4 replace arrows by lines, i.e. translate it into a graph which is indirected. Assume ordering as in 4.b. a.[10] Find a minimumcost spanning tree by Prim’s algorithm. b.[10] Find a minimumcost spanning tree by Kruskal’s algorithm. c.[10] Find a depthfirst spanning tree starting at a. d.[10] Find a breadthfirst spanning tree starting at a. Give all steps. Solutions at the end...
View
Full Document
 Spring '03
 janicki
 Graph Theory, source vertex, adjacency lists, minimumcost spanning tree, incoming arcs

Click to edit the document details