ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1731. Dill

Check your tests.
Posted by larev01 25 Apr 2012 19:31
The tests are a little bit incorrect.
If we have, let's say, 10 boxes of the first variety and 10 boxes of the second variety we can come up with:
1  2  3  4  5  6  7  8  9  10
10 20 30 40 50 60 70 80 90 100
(1 line: from 1 to n; 2 line: from n to m*n with step of n)
In this case we never allocate boxes of even weight. If we take box number 10 from the first line and box number 3 from the second, we get 10+30=40. The best solution would be the box number 1 from the first line and the box number 4 from the second one: 1+40=41. But 40!=41
The system gives me WA on the very first test.
Re: Check your tests.
Posted by Sandro (USU) 25 Apr 2012 23:50
All integers in output must be different, so your answer is wrong.
Re: Check your tests.
Posted by larev01 26 Apr 2012 07:47
Oops... Indeed! Shame on my inattention :(
Thanks, mate!