Question
Official answer and solution
- Official answer
- 5
- From
- Official GATE 2025 answer key
Solution
Find the minimum spanning tree of the graph without edge , identify the maximum edge weight on the unique path between and in that tree, and require to be strictly smaller.
- Consider the graph without edge : its edges sorted by weight are , , , , and .
- By Kruskal's algorithm, the MST of consists of the three edges:
- Adding edge of weight to this tree creates the fundamental cycle , whose other edges have weights and (maximum weight ).
- By the MST cycle property, edge is included in every MST of if and only if its weight is strictly less than the heaviest other edge in this cycle (, since at there is a tie with ).
- Therefore, the maximum integer value of is 5.
Final answer
5
Common trap
Answering 6 by overlooking that the question requires to be included in every MST.
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2025 Computer Science and Information Technology - Session 1 (CS1)
- Question
- 64 of 65
- 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.