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 | 3803 |
2 | jiangly | 3707 |
3 | Benq | 3627 |
4 | ecnerwala | 3584 |
5 | orzdevinwang | 3573 |
6 | Geothermal | 3569 |
6 | cnnfls_csy | 3569 |
8 | Radewoosh | 3542 |
9 | jqdai0815 | 3532 |
10 | gyh20 | 3447 |
# | User | Contrib. |
---|---|---|
1 | awoo | 163 |
1 | maomao90 | 163 |
3 | adamant | 161 |
4 | maroonrk | 152 |
5 | -is-this-fft- | 151 |
6 | nor | 150 |
7 | atcoder_official | 147 |
7 | SecondThread | 147 |
9 | TheScrasse | 146 |
10 | Petr | 145 |
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