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

Автор rinori, история, 4 года назад, По-английски

I get this error on one test case. My program runs properly on the local machine. Then I submitted this code which worked perfectly

https://codeforces.com/contest/988/submission/65531257

What is the reason for this error?

Thank you.

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

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

In case, there are $$$\ge k$$$ distinct integers, you only have to output $$$k$$$ of them, but you are outputting more than $$$k$$$. So, before printing resize $$$B$$$ to $$$k$$$.