1 / 7
Mar 2022

My submission to problem CSTATE1 received Wrong Answer, and when I clicked for more detail it reported that the first file was AC, but all the others say “Result is WA, message is ‘Correct answer for all test cases’”

What does that mean? How can it be WA if all the test cases were correct?

It does sound odd. The messages I got for my WAs made sense. Perhaps @Hodobox could help?

Thanks, how do I do that? (Last seen Jan 2020 anyway). I’ve only just discoverd the feature. I can’t see a report when I submit a correct answer, so would have to deliberately put in known wrong answers to experiment.

I’m hoping he’ll be notified about this thread.

This is what I got for a WA in 2017

File #0: Result is AC, message is ‘Correct answer for all test cases’, time = 0.000000, mem = 608
File #1: Result is AC, message is ‘Correct answer for all test cases’, time = 0.000000, mem = 608
File #2: Result is AC, message is ‘Correct answer for all test cases’, time = 0.000000, mem = 608
File #3: Result is WA, message is ‘Test Case 69: Your answer: White Checkmate; Correct answer: White Check’, time = 0.000000, mem = 608
File #4: Result is WA, message is ‘Test Case 172: Your answer: Black Checkmate; Correct answer: Black Check’, time = 0.000000, mem = 608
File #5: Result is WA, message is ‘Test Case 251: Your answer: White Checkmate; Correct answer: White Check’, time = 0.000000, mem = 608
File #6: Result is WA, message is ‘Test Case 42: Your answer: White Checkmate; Correct answer: White Check’, time = 0.000000, mem = 608
File #7: Result is WA, message is ‘Test Case 92: Your answer: Black Checkmate; Correct answer: Black Check’, time = 0.010000, mem = 608
File #8: Result is WA, message is ‘Test Case 73: Your answer: White Checkmate; Correct answer: White Check’, time = 0.000000, mem = 608
File #9: Result is WA, message is ‘Test Case 127: Your answer: Black Checkmate; Correct answer: Black Check’, time = 0.010000, mem = 608
File #10: Result is WA, message is ‘Test Case 54: Your answer: White Checkmate; Correct answer: White Check’, time = 0.000000, mem = 608
File #11: Result is WA, message is ‘Test Case 85: Your answer: White Checkmate; Correct answer: White Check’, time = 0.000000, mem = 608
File #12: Result is WA, message is ‘Test Case 34: Your answer: Black Checkmate; Correct answer: Black Check’, time = 0.020000, mem = 608

And this is what the same code gets now

File #0: Result is AC, message is ‘Correct answer for all test cases’, time = 0.004190, mem = 5368
File #1: Result is AC, message is ‘Correct answer for all test cases’, time = 0.007124, mem = 5424
File #2: Result is AC, message is ‘Correct answer for all test cases’, time = 0.010278, mem = 5368
File #3: Result is WA, message is ‘Correct answer for all test cases’, time = 0.008550, mem = 5420
File #4: Result is WA, message is ‘Correct answer for all test cases’, time = 0.012957, mem = 5512
File #5: Result is WA, message is ‘Correct answer for all test cases’, time = 0.010443, mem = 5448
File #6: Result is WA, message is ‘Correct answer for all test cases’, time = 0.015139, mem = 5356
File #7: Result is WA, message is ‘Correct answer for all test cases’, time = 0.013124, mem = 5404
File #8: Result is WA, message is ‘Correct answer for all test cases’, time = 0.009311, mem = 5268
File #9: Result is WA, message is ‘Correct answer for all test cases’, time = 0.013544, mem = 5452
File #10: Result is WA, message is ‘Correct answer for all test cases’, time = 0.013334, mem = 5404
File #11: Result is WA, message is ‘Correct answer for all test cases’, time = 0.013728, mem = 5368
File #12: Result is WA, message is ‘Correct answer for all test cases’, time = 0.025035, mem = 5308

Thanks, that is what I got (with only File #0 AC). You may have noticed I previously got an “internal judge error” of time limit there, which has never happened before on Qs where I used a faster method of I/O. I got past that by using the more usual ways. So perhaps it’s broken.

Hi there,

sadly it seems that SPOJ changed something about the way the custom judge is used or executed, and it broke. The way it works iirc is SPOJ allows me to return some ‘score’ from the checker, and so I send a bitmask indicating something like ‘your colour/your answer/correct colour/correct answer’ and print a message based off that.

I don’t think I’ll get around to figuring out this issue soon, given that a) SPOJ didn’t let us know they were breaking something b) documentation/UI sucks in general c) couldn’t remember where I put the custom judge locally anyway (did I mention UI sucks? I can’t download it from the site).

I changed it just to a regular judge (compare output -> WA/AC) for now. It seems though that the WA/AC works fine, so if you want to risk weird internal errors if you ‘mess around’ with IO too much, I can put it back, and you might at least know which piece gives you trouble.

gl hf,
Hodobox