1
$\begingroup$

$A$ and $B$ play the following game. Initially, for positive integer $n$, each player takes turns choosing one of three numbers:

  • $1$

  • the number of digits of $n$

  • the sum of the digits of $n$.

and then updates the number $n$ by subtracting the number selected. If $n$ becomes $0$, the person who has that turn wins. Who will be the winner if $A$ is always the first to go?

For example:

  • With $n=3$, the result is $A$, because $A$ chooses the number that is the sum of the digits of $n = 3$, after selecting, $n$ is updated and becomes $0$. So $A$ wins.

  • With $n=10$, the result is $B$, because $A$ can only choose $1$ or $2$ (because the number of digits of $10$ is $2$ and the sum of the digits of $10$ is $1$). So, when choosing, $n$ can only be $8$ or $9$. Next $B$ selects $8$ or $9$ and wins.

My problem is to determine who the winner is when $n$ is known.

$\endgroup$
17
  • 1
    $\begingroup$ And how far have you gotten with it? $\endgroup$
    – saulspatz
    May 4, 2019 at 8:41
  • 3
    $\begingroup$ Try figuring out who wins if the the number is $11,12,13,\dots$ and see if can find a pattern. $\endgroup$
    – saulspatz
    May 4, 2019 at 8:50
  • 1
    $\begingroup$ If the number is $13$, A loses. Also, three examples are nowhere near enough. Actually, I don't see a pattern here. Are you supposed to find a formula or write a computer program? $\endgroup$
    – saulspatz
    May 4, 2019 at 9:11
  • 1
    $\begingroup$ I don't see a formula either. It seems very erratic. $\endgroup$
    – saulspatz
    May 4, 2019 at 9:17
  • 1
    $\begingroup$ Also posted to MO, mathoverflow.net/questions/330743/… with no notice to either site. THAT'S AN ABUSE! $\endgroup$ May 4, 2019 at 23:09

0

You must log in to answer this question.

Browse other questions tagged .