|
|
back to boardWA9 Posted by Carbon 6 Jan 2008 03:12 By my mind, my solution is right. It builds a shedule of transporting with maximal money values superseding least values before that time. But my solution falls on ninth test. I think that something wrong with that test. Re: WA9 There are greedy simple solution. Just sort works into descending order of profits and process them sequentally. Re: WA9 Posted by Carbon 30 Jan 2008 18:30 Oh! Thank you! I've got AC. My time is 0.001. Re: WA9 And then what in case of test? 1 3 2 9 Re: WA9 Posted by R1d1 28 Dec 2008 17:15 4 1 4 1 2 2 5 2 2 Answer: 2 1 3 Re: WA9 More likely a test like: 4 2 2 2 3 3 4 3 5 will yield WA9. Re: WA9 9 1 100 1 50 1 150 2 10 2 20 2 10 3 5 3 7 3 5 ---------- 3 3 5 8 |
|
|