Problem

Source: Cono Sur 2021 P4

Tags: combinatorics, Combinatorial games



In a heap there are $2021$ stones. Two players $A$ and $B$ play removing stones of the pile, alternately starting with $A$. A valid move for $A$ consists of remove $1, 2$ or $7$ stones. A valid move for B is to remove $1, 3, 4$ or $6$ stones. The player who leaves the pile empty after making a valid move wins. Determine if some of the players have a winning strategy. If such a strategy exists, explain it.