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

Автор mufaddalnaya, история, 5 лет назад, По-английски

I've tried submitting a solution to problem 1146C — Tree Diameter Submission

But I get Idleness limit exceeded on test 1, I tested my code using Custom Test, but it seems to be working Okay, how can I fix this?

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

»
5 лет назад, # |
  Проголосовать: нравится +13 Проголосовать: не нравится

After printing a query do not forget to output end of line and flush the output. Otherwise, you will get Idleness limit exceeded. To do this, use:

fflush(stdout) or cout.flush() in C++;
System.out.flush() in Java;
flush(output) in Pascal;
stdout.flush() in Python;
see documentation for other languages.