Please read the new rule regarding the restriction on the use of AI tools. ×

__Serendipity's blog

By __Serendipity, history, 23 months ago, In English

Given an undirected weighted graph G, with N nodes and E edges. You have to answer Q queries.

In each query, you are given two nodes u and v. The answer to the query is the minimum value k such that there is a path from node u to node v such that the maximum weight of the edge in path is at most k.

Constraints : N,E,Q <= 10^5

Can anyone please explain me how to solve this problem!

Full text and comments »

  • Vote: I like it
  • -5
  • Vote: I do not like it