GATE / CS ARCHIVE

GATE CSE 2006 / QUESTION 47

Kruskal's edge order

Algorithms · Graph Algorithms · Full GATE CSE 2006 paper

GATE 2006, Q47 2 marks · MCQ
Report issue

Graph Algorithms

Question 47, GATE 2006: An undirected graph has vertices a,b,c,d,e,f and weighted edges ab:1, ac:6, bc:3, bd:4, bf:2, cd:2, ce:4, cf:7, de:3, df:1, ef:5. Which sequence cannot be the edges added, in order, by Kruskal’s minimum-spanning-tree algorithm? GFG A prints af, an edge absent from the graph; GateForum A instead prints df. Both readings are retained.
Options:
(A) ab, af, bf, dc, de [GFG]; ab, df, bf, dc, de [GateForum]
(B) ab, df, dc, bf, de
(C) df, ab, dc, bf, de
(D) df, ab, bf, de, dc
Question 47, GATE 2006: An undirected graph has vertices a,b,c,d,e,f and weighted edges ab:1, ac:6, bc:3, bd:4, bf:2, cd:2, ce:4, cf:7, de:3, df:1, ef:5. Which sequence cannot be the edges added, in order, by Kruskal’s minimum-spanning-tree algorithm? GFG A prints af, an edge absent from the graph; GateForum A instead prints df. Both readings are retained.
Options:
(A) ab, af, bf, dc, de [GFG]; ab, df, bf, dc, de [GateForum]
(B) ab, df, dc, bf, de
(C) df, ab, dc, bf, de
(D) df, ab, bf, de, dc
Tap to enlarge
Your answer
Answer & solution

Answer: A, D (no official key was published)

1. The graph has ab=df=1, bf=dc=2, and de=bc=3. Kruskal first adds ab and df in either order, then bf and dc in either order, then de.

2. B and C are legal. D adds de of weight 3 before dc of weight 2, although dc still joins distinct components, so D is impossible.

3. However, the paper prints (a-f) as the second edge of A; no such edge exists, making A impossible too. Replacing that entry with (d-f) would make A legal and yield the intended unique answer D.

4. This is a the paper-specific ambiguity, not an established defect in the original exam.

6. Teaching check: Kruskal processes available edges in nondecreasing weight and only skips an edge when its endpoints are already connected. Tie order can vary for equal weights, but it cannot justify selecting weight 3 while a useful weight-2 edge remains. The absent af edge is a separate transcription defect.

Original paper, page 6