Data Structures & AlgorithmsHardICPC regional · GATE CS top band
Undirected weighted graph on vertices A, B, C, D, E, F with edges A–B (1), A–C (3), B–C (7), B–D (5), B–E (7), B–F (7), C–F (2), D–E (1), E–F (2). Over all paths from A to D, minimise the largest single edge weight used on the path. What is that minimum possible largest edge weight?
- A. 3
- B. 7
- C. 5
- D. 6
Correct answer: A. 3
The minimax (bottleneck) value is 3, which equals the largest edge on the MST path between the two vertices. The shortest-path bottleneck is 5, so minimising path length is not the same as minimising the largest edge.
Practise more Trees, Graphs, Recursion and Dynamic Programming questionsTrees, Graphs, Recursion and Dynamic Programming: notes and key points
More Trees, Graphs, Recursion and Dynamic Programming questions
- Undirected graph on vertices A, B, C, D, E, F, G with weighted edges A–C (7), A–D (7), B–C (4), B–F (9), B–G (5), C–F (5), D–F (1), E–F…
- Keys are inserted in the order 12 31 77 11 65 57 into an empty binary search tree. Then the key 12 (which has two children) is deleted by…
- Distinct words ['aa', 'ab', 'bb', 'ca', 'aab'] are inserted into an empty trie (one node per character, shared prefixes share nodes, and a…
- Keys are inserted in the order 11 88 20 15 45 into an empty binary search tree. Then the key 20 (which has two children) is deleted by…
- Consider the recursive function def f(n): if n < 2: return n; return f(n-1) + f(n-2). Evaluate f(6) and count every invocation of f…
- Words ['bdc', 'dd', 'dba', 'ddc', 'ccb'] (each may be used at most once). A chain is a sequence of these words in which the first letter…