|
|
|
|
|
by clintonc
1385 days ago
|
|
> Note: In this implementation, jumping off the board is only possible if the stack can reach exactly 1 row or column beyond the perimeter. But it seems to always be the case that it is possible to jump off the board when a stack is big enough. Please let Michael know if you encounter a scenario where a piece is stuck. This should not be allowed according to the rules of the game. True. Suppose you moved from A to B, and your stack just became 8 tall. Then you must have jumped from one edge of the board to the other; if you jump back the way you came, you'll land on the "margin" outside of the board. Also, there are no other legal moves besides jumping onto the margin; in particular, you can never become 9 tall. Repeat for smaller heights: If you are height N, but no other moves land on the board, then moving back in the direction the piece last came from will put it on the margin. |
|
But I confused this with a stack being completely stuck, i.e. not having any moves, which is a different question. That's the situation I vaguely saw was impossible.