Question
Official answer and solution
- Official answer
- 4
- From
- Official GATE 2018 answer key
Solution
Use Kruskal's algorithm principles to choose so that ties at critical cuts create the maximum number of distinct MWSTs.
The graph has 5 vertices and 7 edges with weights: .
Edges [weight 1] and [weight 3] have the smallest weights and must be included in every MWST, connecting component . Edge of weight 4 creates a cycle with them and is never selected.
To connect to , there are two edges of weight 4: and . Choosing either edge connects at minimal cost, giving independent choices.
To connect , the available edges are of weight and of weight 5.
- If , is strictly smaller, giving only 1 choice for .
- If , is strictly smaller, giving only 1 choice for .
- If , both and have weight 5, giving independent choices for .
Thus, setting maximizes the number of MWSTs to .
4
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2018 Computer Science and Information Technology (CS)
- Question
- 57 of 65, printed as CS Q.47
- Section
- Computer Science and Information Technology
Report an error in this question
GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.