secomo's blog

By secomo, history, 3 years ago, In English

my code has worked on codeblocks and when I send it. it is getting wrong answer on test 1 and the test message form is: " Wrong outout formats (0 elements printed ) unexpected end of file "

any help would be great

Spoiler
  • Vote: I like it
  • -18
  • Vote: I do not like it

»
3 years ago, # |
  Vote: I like it 0 Vote: I do not like it

Auto comment: topic has been updated by secomo (previous revision, new revision, compare).

»
3 years ago, # |
  Vote: I like it +3 Vote: I do not like it

Please provide the problem link. It's not possible to find out the error without problem statement.

»
3 years ago, # |
  Vote: I like it 0 Vote: I do not like it

The code is unreadable, and you didn't provide the statement to the problem, it really looks like you don't want to be helped.

Fortunately for you, your mistake was simple: you used #define cout cerr. Cout writes in the standard output, which codeforces reads. Cerr writes in the error output which it doesn't.

I don't know why you would put that line in and i recomend not using defines at all until you're experienced enough to understand when you shouldn't use it.

»
3 years ago, # |
  Vote: I like it +3 Vote: I do not like it
  1. format the code.
  2. add problem link.