Problem hidden
This problem was hidden by Editorial Board member probably because it has incorrect language version or invalid test data, or description of the problem is not clear.

BALLSREM - Remove the Balls

There are n boxes with mi balls in box i. Two players by turns must take away from a single box an arbitrary number of balls but at least one. You as one of the players start removing balls. If you take the last ball you lose.

Input

In the first line the number T of test cases (T<=100).
Then T lines with n (3<=n<=21) numbers mi (0<mi<100).

Output

For each test case win if you could win the game otherwise lose.

Example

Input:
3
1 1 1
1 1 2
1 1 1 1 Output: lose
win
win

Added by:HWK
Date:2011-05-21
Time limit:6.533s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: SCM qobi

hide comments
2013-12-05 21:09:06 Jander
@challenger - There are missing tests which my 44 Perl gives the wrong answer for. It's worth adding:

10 10 1 1
11 11 1 1

and rejudging.
2011-09-08 15:07:42 HWK
@Jander: Fine! So I'm satisfied.
2011-09-08 11:25:34 Jander
Oh yes, so it does :-) Still, there is a test case that my AC code should fail on. Now to look at why my new code give so many WAs.

Edit #1: Ah, I can see it now.

Edit #2: It's okay. My current AC code is correct :-) I was checking against some test cases that are outside the range of the defined input. Just me having a brain fart.

Last edit: 2011-09-08 12:22:11
2011-09-08 10:45:20 HWK
@Jander: Your WA-solution results in a lot of errors. E.g. check the 3 examples.
2011-09-08 08:58:43 Jander
HWK - Can you pop on to IRC some time? I think there's a faulty test case. My current winning/AC code ought to fail on a certain test case. I fixed my code to deal with that but it now gets WA so I think there may be a missing and an incorrect test case.
2011-07-30 18:37:04 HWK
@hallvabo: No, only the best one. 7 bytes less. Come on! ;-)
2011-07-30 11:16:45 Hallvard Norheim Bø
@HWK: you might want to challenge my two bash solutions :)
2011-06-01 12:00:53 HWK
That puts my mind at rest. :-)
But seriously: Go on shortening. It motivates me to write shorter solutions even though they are no Perl ones. E.g. look at EQCHECK. ;-)

Last edit: 2011-06-01 12:34:29
2011-05-31 19:02:32 Jander
@HWK: Don't worry - many 1st places are safe as I'm consciously sticking only to Perl solutions. There are ones of Challenger's and Shinichiro's that I've still to work out what they're doing.

Last edit: 2011-05-31 19:02:52
2011-05-31 16:41:38 HWK
@Jander: Congratulations!
But it seems that you and Nabb have it in for me. All my first places got lost. :-(
© Spoj.com. All Rights Reserved. Spoj uses Sphere Engine™ © by Sphere Research Labs.