Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Scala translation
needs
restricted
( or similar ) tag( Python )
This is not tested
( Python, possibly others )
Random tests generate out of bounds cases. Description promises us max 6 elements. It doesn't matter for the logic of course, but specs are specs.
Thanks for creating this kata! Very impressive testing.
Suggestion: Change "he" to "they" in the description. Not only males play Reversi (Othello).
It would be fun if the performance of the user's code compared with the reference implementation was displayed.
(JS, possibly others)
Description could be improved:
null
if the array is empty"n-1
array ofBoolean
s. it's more of a rolling result; each prefix result implies the next value, recursively.The empty array case is completely arbitrary ( returning
True
would actually make more sense ); also,[False]
by itself should also really returnTrue
IMO. Why are lengths < 2 even tested? Just don't.Maximising array length at 8 is also arbitrary. You're not going to hardcode this, are you? ( Actually, the tests are hardcoded. I would definitely have done that algorithmically! O.O ) But there will always be some limit, and 8 is as good as any.
Do test cases cover the following situations? If not there should. (A and B represent PlayerA and PlayerB)
For test
['f5f4f3g4e3e6g3d3c4c5c3b4d6d2g6f6e7e2f2h3b6g5f7c6h5d7h4e8h2a6c8g7g2h6d8h1h8h7e1g1f1d1c7b7a8b8c1c2b5a5g8f8b2b1a4a2a1b3a3a7', ['C',None,'B',38,26]]
According to my calculation, the last a7 is a invalid move because the board is
Did i miss anything?
Step by step move
Some questions need to be clarified:
Is the chessboard size always be 8 x 8?
What's the state of
Complete
? Only one kind(black or white) one the board?What's the state of
Error
? movelist contains invalid move(such as f9, f0, z1..)? or duplicate movements?What's the mean of
'f5f4f3g4e3e6g3d3c4c5c3b4d6d2g6f6e7e2f2h3b6g5f7c6h5d7h4e8h2a6c8g7g2h6d8h1h8h7e1g1f1d1c7b7a8b8c1c2b5a5g8f8b2b1a4a2a1b3a3a7'
(I can guess what this is, but you should tell us in the description)