Implementation problem of the Dijkstra Algorithm

Правка en1, от roycf123, 2023-07-24 10:01:56

Recently, I was solving the Graphs section of the CSES problemset and encountered this problem. I used dijkstra algorithm to solve it.

I generally use the template from here, but in this question, this implementation gave me WA. When I used another implementation using visited array, it gave AC.

WA code
Теги graphs, dijkstras validity, dijkstra

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский roycf123 2023-07-24 10:10:22 3435 (published)
en1 Английский roycf123 2023-07-24 10:01:56 2034 Initial revision (saved to drafts)