Alice and Bob play a game on a strip of $n \geq 3$ squares with two game pieces. At the beginning, Alice's piece is on the first square and Bob's piece is on the last square. The figure shows the initial position for a strip of $n=7$ squares.

Moves are made alternately. A move consists of moving one's own piece one or two squares towards the opponent's piece onto an empty square, without jumping over the opponent's piece. Alice makes the first move with her piece. The player who cannot make a move loses.

For which $n$ can Bob surely win, regardless of how Alice plays? For which $n$ can Alice surely win, regardless of how Bob plays?

(Karl Czakler)

Answer. Bob wins for $n=3k+2$ with $k \in \mathbb{Z}_{\geq 1}$, Alice for all other $n \geq 3$.
It is easy to consider that for a row of $n=3,4,6$ or $n=7$ fields Alice wins, whereas for a row of $n=5$ or $n=8$ fields Bob wins.

All rows with $n=2+3k$ fields are winning positions for Bob, as it is always possible for him to reduce the distance between the two stones by exactly three, by always complementing the number of Alice's move to 3. Thus, he can eventually reach the winning position $n=5$.

For $n=3k$, Alice wins if she moves her stone forward by one field on her first move. Bob can then either move two or one field further, reducing the number of fields by three or two, respectively. We again have a winning position for Alice with $n=3k-3=3(k-1)$ or $n=3k-2=3(k-1)+1$ fields.

For $n=3k+1$, Alice wins if she moves her stone forward by two fields on her first move. Bob can then either move two or one field further, reducing the number of fields by four or three, respectively. We again have a winning position for Alice with $n=3k+1-4=3(k-1)$ or $n=3k+1-3=3(k-1)+1$ fields.

Alice thus reaches one of the two winning positions $n=3$ or $n=4$ in both cases. All rows with $n=3k$ or $n=3k+1$ fields are therefore winning positions for Alice.

(Karl Czakler)