Usually when it says “wrong answer,” I double check everything because I know something is wrong. But in this case, on my last submission I had, what I believe, to be perfect answers.
I went through the difficulty of checking test cases 4-10, by hand, which was quite boring. And yes, they were all correct.
Not only that, but I used a much slower algorithm (which I am extremely confident of), which was also consistent, for much higher test cases.
The only possible explanation is, maybe, I’m missing something about the problem.
Try understanding the constraints correctly. It may help you in finding the solution for your problem.
Strategies of on-going contest can’t be discussed during the period of contest.
The answer for 2400 of my code is 32380837031
The answer for 2500 of my code is 36812076035
So they are positive…
I’ve checked it by hand, and… since the contest is over (sorry for asking the question before it was over), I’m still looking at the other players’ solutions. Thanks guys for responding, and … hopefully I’ll figure this out =) I’m sure there’s something wrong with my code…
And btw, (really, no offense to any people who designed the solutions viewer), but why does the solutions viewer… well, not view things in a very good font? Somethings are in a nice coding font, but some are in non-code font (I use Google Chrome), and… the indentation isn’t the best… I usually copy everything into my IDE just to see things properly. It would be a bonus if viewing submitted code on CodeChef website was more beautiful. =]
@formatting: viewer is not formatting it, just highlighting for example keywords. If not intended properly, that’s because contestant uploaded it so. We see that often in forum also