Congested Walkway

Logic Level 1

Dan and Sam play a game on a 4 × 9 4\times9 grid, in which one takes squares (red) and the other takes circles (blue). Once the game starts, they take turns moving a single piece in their turn. Each piece can only be moved straight forward or backward, any number of grids (and cannot skip over the opponent's piece). This is the initial position:

A player loses when he is not able to move any of his pieces in his turn. If Dan goes first, who will win? In other words, who has a winning strategy?


This is the twelfth problem of the set Winning Strategies .
Dan Sam Neither

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Maggie Miller
May 1, 2016

Relevant wiki: Combinatorial Games - Winning Positions

Playing this game on an n n by m m grid is equivalent to playing Nim with m m piles of n 2 n-2 sticks (the rows corresponding to piles and free squares to sticks). Understanding the game of Nim (also an interesting exercise) tells you that if m m is even and both players play optimally, then the second player ( Sam \boxed{\text{Sam}} ) will win. If m m is odd, then the first play will win.

Good observation about Nim. I know the game but I try to post original games that I create. Can you explain the winning strategy?

Mateo Matijasevick - 5 years, 1 month ago

I'm not sure if this is exactly the same as Nim because "each piece can be moved only forward or backward". This is like you can increase the number of sticks in Nim. In that case, is the answer the same?

Christopher Boo - 4 years, 11 months ago

Log in to reply

Suppose the board in classical Nim is in a losing position on your turn. If you put some of the sticks you had taken from one of the piles back into their original pile, then your opponent can just take those same sticks away on their turn. You're back into the same losing position and you're holding fewer sticks.

It's not the exact same as classical Nim, but in the context of optimal strategies and assuming you don't care about the number of turns, the difference amounts to a rule that says "You can give your sticks to your opponent at any time and it doesn't count as a turn". This type of rule has no effect on optimal strategies.

Brian Moehring - 2 years, 11 months ago

yes. just mirror the move .

Rajkumar Rao - 2 weeks, 2 days ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...