Codeforces Round 1133 (Div. 1, Div. 2) is coming soon! Register here. ×

aajjbb's blog

By aajjbb, 14 years ago, In English

Hi, I'm failing on test case #31 in the problem Dijkstra? from Codeforces Alpha Round #20 (Codeforces format) Link to the Problem, but I'm not able to test it locally because the test case is too big, it's hidden in the submit link.

There's a way to see this full test ? The problem itself is tricky, asking for a as fast as possible Dijsktra implementation, can you guys see what's wrong with this code ? Code

  • Vote: I like it
  • +7
  • Vote: I do not like it

»
14 years ago, hide # |
← Rev. 3  
Vote: I like it +6 Vote: I do not like it

Length of the shortest path can be (n - 1)·w = 1011, which fits long long but is greater than your INF.

Probably, the 31st test has answer with answer  = 109.

»
14 years ago, hide # |
← Rev. 5  
Vote: I like it +1 Vote: I do not like it

You have to increase your INF

UPD:Too slow

1904852