GATE | GATE-CS-2003 | Question 90
What is the weight of a minimum spanning tree of the following graph ?
In these type of questions, always go for kruskal’s algorithm to find out the the minimum spanning tree as it is easy and there are less chances of doing silly mistakes.
Always pick the minimum edge weight and try to add to current forest (Collection of Trees) if no cycle is formed else discard.
As soon as u have added n-1 edges to the forest, stop and you have got your minimum spanning tree.
See the below image for construction of MST of this question.
Weight of minimum spanning tree = Sum of all the edges in Minimum Spanning tree
This explanation has been provided by Pranjul Ahuja.
Visit the following links to learn more:
Attention reader! Don’t stop learning now. Practice GATE exam well before the actual exam with the subject-wise and overall quizzes available in GATE Test Series Course.
Learn all GATE CS concepts with Free Live Classes on our youtube channel.