players kids sit in a circle, in seats numbered 1 to players clockwise; after seat players comes seat 1 again.
The kid in seat 1 holds the ball first and throws it step seats clockwise. Whoever catches it throws it 2·step seats on, the next one 3·step seats, and so on: every new throw goes step seats farther than the last.
The game stops as soon as someone gets the ball for the second time. Return, in increasing order, the seat numbers of the kids who never held the ball.players=6, step=2 → [2, 4, 5, 6]
Player 1 starts. A throw of 2 seats reaches player 3, a throw of 4 seats brings it back to player 1, who now holds it a second time, so the game ends. Players 2, 4, 5 and 6 never held the ball.
players=3, step=1 → [3]
1 → 2 (one seat) → 1 (two seats). Player 3 never got the ball.
players=8, step=3 → []
step ≤ players ≤ 50players=6, step=2
[2, 4, 5, 6]
Run checks the first 3 tests in your browser. Submit checks all 76 tests on the server, hidden ones included.