Testdata doesn't satisfy the constraints mentioned in the problem statement, you can check yourself
Here's the code I used to test this:
# | User | Rating |
---|---|---|
1 | tourist | 4009 |
2 | jiangly | 3823 |
3 | Benq | 3738 |
4 | Radewoosh | 3633 |
5 | jqdai0815 | 3620 |
6 | orzdevinwang | 3529 |
7 | ecnerwala | 3446 |
8 | Um_nik | 3396 |
9 | ksun48 | 3390 |
10 | gamegame | 3386 |
# | User | Contrib. |
---|---|---|
1 | cry | 164 |
1 | maomao90 | 164 |
3 | Um_nik | 163 |
4 | atcoder_official | 160 |
4 | adamant | 160 |
6 | -is-this-fft- | 158 |
7 | awoo | 157 |
8 | TheScrasse | 154 |
8 | Dominater069 | 154 |
8 | nor | 154 |
Testdata doesn't satisfy the constraints mentioned in the problem statement, you can check yourself
Here's the code I used to test this:
Name |
---|
Quite strange.
I agree, I wrote the sieve of Eratosthenes before <=1e9 and it did not go, although it should have, but it goes before <=1e10
The second data is:
and it is simply satisfying the constraints.
well, n = 1 is not satisfying the constraints
oh well, my fault.
As far as i remember this wasn't the second test case. Second test case was a single test case with large N. maybe test data was modified. Though not sure.
I had the same thing but with problem B. My complier showed me one Test 1 result(4 and 5), whereas the system displayed the other one(3 and 4). So, first, I had to rewrite my solution in python, then because of ML error develop one more algorithm in C++. That was quite strange.
I saw your code this is due to the garbage value in 'graph[][]' as you have not initialized it, here's your code with minor changes https://codeforces.net/contest/1771/submission/184817181, and RTE on test2 is due to the fact you are making a very large array of size ~1e10
Yes, we are sorry for it. Please, read https://codeforces.net/blog/entry/109892?#comment-979226