Data Structures & AlgorithmsHardCodeforces Div 2 C · ICPC regional

Undirected weighted graph on vertices 0 to 6 with edges: 4–5 (1), 2–6 (13), 0–6 (11), 0–1 (2), 2–4 (4), 0–4 (4), 0–5 (9), 5–6 (15), 4–6 (8), 1–5 (13), 1–6 (13), 3–5 (11), 2–5 (10), 2–3 (10). Over all paths from 0 to 6, what is the smallest possible value of the heaviest edge on the path (the bottleneck or minimax path weight)?

  1. A. 11
  2. B. 29
  3. C. 8
  4. D. 2

Correct answer: C. 8

Adding edges in increasing weight until 0 and 6 become connected gives bottleneck 8. The minimum total path weight (11), the MST weight (29) and the lightest edge at 0 (2) answer different questions.

More Trees, Graphs, Recursion and Dynamic Programming questions

Exams that ask this topic