Consider an n × n board with n ≥ 2 distinct colors. There is exactly one circle of each color. Every remaining cell is either empty or contains a square of one of the n colors. The initial arrangement is arbitrary.
A move consists of swiping a row left or right, or a column up or down, subject to the following rules:
- A row or column can be swiped only if it contains at least one circle.
- Pieces wrap around the edges of the board.
Before anything moves, each circle in the swiped line examines the cell immediately behind it relative to the swipe direction. For example, on a rightward swipe, each circle examines the cell immediately to its left, with wraparound.
- If that cell contains a square of the circle's color, the circle remains stationary and the square becomes an empty space.
- If that cell is empty, the circle remains stationary and the empty space becomes a square of the circle's color.
- If that cell contains a different-colored square or another circle, the circle moves with the rotation.
- Once all stationary circles and transformations have been determined, cyclically rotate the contents of the remaining cells by one position in the swipe direction, skipping the cells occupied by stationary circles.
All transformations are determined from the configuration before the move and occur simultaneously. Circles can never be removed.
Prove that, regardless of the initial configuration, there exists a finite sequence of moves that removes every square from the board.
This problem arose while I was designing a puzzle game called Tile Wipeout. ChatGPT found a constructive proof for arbitrary n that does not require exhaustive computer search.