Wrong Answer because of last blank in the printf
itmir913 opened this issue · comments
Hello. Thanks for your OJ.
The last space in the sentence is treated as an incorrect answer.
for example,
my output is:
5 3 1(blank)
6 4 2(blank)
and tast case is:
5 3 1
6 4 2
There is a space at the end of the sentence in my output.
But tast case is not like that.
and there is also the opposite case. (tast case is a space at the end of the sentence, and output is not)
in this situation, I would like to admit it as an answer.
What should I do?
Judger simply generates an output file of the submitted code. The JudgeServer compares the md5 hash value of user output file with of the correct output file to check the answer is correct. The last line is processed by rstrip(), but the inside spaces are not. You need to change the process of checking the answer.
Check the line 165 of judge_client in the JudgeServer
https://github.com/QingdaoU/JudgeServer/blob/master/server/judge_client.py
As someone who has experienced the same issue, i hope this helps!
Thanks for your reply!