Why did I Score Zero?
Sometimes you will score zero even though you believe you have a working solution to a problem.
You can check the Submission details pop-up of each submission to see the reasons why your solution was not judged as correct. See the Student contest guide for more information.Below are some of the common reasons that good solutions score zero.
Incorrect input and output files
Each problem statement lists the names of its input and output files, similar to the example below.
In this example, if you try to open any of
input.txt, then your program will fail
on the judging machine and your program will score zero.
robotin.txt without any additional
directory information. The same goes for the output file.
Incorrect output format
Each problem is very precise about how the output file should be formatted. Your score is assigned by a judging program which tries to automatically extract your solution from your output file.
Every problem statement includes sample input and output files, as a way
of illustrating these formats. For example, if the correct output should be the single integer:
4, then the following outputs would be judged as incorrect:
The answer is 4
4to the screen.
Incorrect problem/language selected
Double-check that you are submitting your solution to the right problem. Also check that you have selected the correct language from the drop-down box when submitting your solution.
Points for submissions are awarded in Subtasks. Your solution must be judged as "Correct" for all of the judges' test cases within a subtask for you to obtain those points. If your program exceeds the time limit, produces an incorrect output or a runtime error on even a single case, you will score zero for that subtask.
Incorrect mode for output file
You must only open the output file for writing, not writing and updating. In
particular, in Python you must open the output file with mode
w+. This is one of the reasons you may receive "Execution failed
because the return code was nonzero" as feedback. The best way to avoid this
type of error is to use the solution templates.