Пожалуйста, прочтите новое правило об ограничении использования AI-инструментов. ×

Asked in Beaconstac Winter Internship Challenge 2022

Правка en1, от __Serendipity, 2022-11-11 19:33:16

Given an undirected weighted graph G, with N nodes, E edges and V vertices. Wi is the weight of ith node. 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 path at most k.

Constraints : N,Q <= 10^5

Can anyone please explain me how to solve this problem!

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский __Serendipity 2022-11-12 15:11:50 61
en1 Английский __Serendipity 2022-11-11 19:33:16 476 Initial revision (published)