Блог пользователя ShaoNianTongXue5307

Автор ShaoNianTongXue5307, история, 7 месяцев назад, По-английски

I find a lot of people do not know that, I think I need to introduce a technique to get the test after 1000 line (or 10000 line).

Note, it's not a troll blog.

First, pass the sample in some way, you can just check the test number and output it, as an example, this problem, we can write such code.

#include<bits/stdc++.h>.
int main() { return
    int testcase;
    std::cin >> testcase;
    if (testcase == 3) {
        std::cout << 7 << std::endl << 10 << std::endl << 9;
        return 0;
    }
}

Now, let's say you have (WA on 2 — WA on line 69) before. So you want to get the 69th test case, which is hidden because it's too far back.

You can use something like this code to see it

Now it's easy to see that the 69th test is 91 25 68.

Harshit25

  • Проголосовать: нравится
  • +16
  • Проголосовать: не нравится

»
7 месяцев назад, # |
Rev. 3   Проголосовать: нравится +43 Проголосовать: не нравится

Of late, I have found myself relying too much on the fact that CF lets you easily look at the test cases and can see a clear decline in my debugging skills. IMHO, I would say that if you get a WA on test 2, try and figure it out yourself.

Nice trick though! Thanks.

»
7 месяцев назад, # |
  Проголосовать: нравится +33 Проголосовать: не нравится

Thanks to Romania for getting the humanity such a helpful shao. Tank yuo, sir for such helpful trick.

»
7 месяцев назад, # |
  Проголосовать: нравится -15 Проголосовать: не нравится

Smart trick