The subtraction game

Intermediate Mathematics English
Also available: Deutsch
Created by Best · 17.07.2026 at 11:55 UTC

In the subtraction game a single pile holds some tokens, and each turn a player removes between $1$ and $k$ of them. Whoever takes the last token wins. The losing positions are the multiples of $k+1$: if the pile is a multiple of $k+1$ on your turn, any move lets the opponent restore a multiple of $k+1$, and you are eventually handed the loss.

So the winning move is always to leave a multiple of $k+1$. Only the pile size modulo $k+1$ matters, not its full size, which is modular arithmetic doing the work.

University approvals: 0
Tasks
Question 1

Play the subtraction game: take 1 to 3 tokens on your turn. Take the last token to win. The computer plays perfectly.

Question 2

A pile holds 22 tokens and each turn removes 1 to 4. What is your winning move?

Question 3

Which quantity alone decides the winning move?

Card Info
  • Topic: Mathematics
  • Difficulty: Intermediate
  • Completed: 0 users
Creator
Best
Best
BestBuddy