Cayley's mousetrap
From Wikipedia, the free encyclopedia
Mousetrap is the name of a game introduced by the English mathematician Arthur Cayley. In the game, cards numbered one through n are placed in some random permutation. Then, starting with the left-most card, the player begins counting "1, 2, 3, ...", moving to the next card as they increment their count. If at any point the player's current count matches the number on the card currently being pointed to, that card is removed, and the player starts over at one on the next card. When the player reaches the end of the cards (the right-most card), they simply wrap around to the left-most card and continue counting. If the player ever removes all of the cards from the permutation in this manner, then the player wins. If the player reaches n and cards still remain, then the cards win.