ale's blog

By ale, history, 4 years ago, In English

I have been trying to solve problem XMart but getting WA. Then I look for some test cases online and find out that my program fails on this test case

7 6
0 0 1 2
0 0 1 5
2 3 0 0
4 5 0 0
0 0 3 4
0 0 3 6
2 6 0 0

my solution says it's possible to satisfy all customers with this configuration

1 - sell
2 - keep
3 - keep
4 - sell
5 - keep
6 - sell

but the expected ouput is "no". Can someone tell me if it's some understanding error of the problem or is the test case wrong.

Full text and comments »

  • Vote: I like it
  • 0
  • Vote: I do not like it