Page:Bouton - Nim.djvu/5

Rh player who first leaves a safe combination can do so at every subsequent play, and will win. The induction proof is so direct that it seems unnecessary to give it.

6. Modification. The game may be modified by agreeing that the player who takes the last counter from the table loses. This modification of the three pile game seems to be more widely known than that first described, but its theory is not quite so simple.

A safe combination is defined just as in the first case, except that 1,1,0 is not a safe combination, and 1,1,1 and 1,0,0, are safe combinations. When the first theory indicates that A should play 1,1,0 he must play either 1,1,1 or 1,0,0. The earlier part of the proof proceeds as before. In order to complete it, we must show that B can never leave 1,1,1; that, when 1,1,0 is indicated for A, he can always play either 1,0,0 or 1,1,1; and finally that, if the play is carried out in this way, B must take the last counter. That B can never leave 1,1,1 is at once clear, for A never leaves 1,1,n where n > 1, since this is not a safe combination. Secondly, let us consider what sets of numbers B can leave which would indicate 1,1,0 as A's next play in the first form of game. They are 1,1,n where n > 1, and 1,n,0 where n > 1. In the first case A leaves 1,1,1 and in the second 1,0,0. The proof is now easily completed. Either A or B reduces a pile to zero. If B does so, the other two piles are unequal and both greater than unity, or at least one of the two remaining piles is unity. In the latter case A obviously wins. In the former case A makes the two piles equal, and then keeps them equal until B reduces one of them to 1 or 0. If B makes it 1, A takes all the other pile; if B makes it 0, A takes all but 1 of the other pile. Hence if B first reduces a pile to zero A wins. If A first reduces a pile to zero he leaves the other two piles equal and each greater than unity, and wins as before. Hence if A plays on the safe combinations as here modified, B must take the last counter from the table, and loses. That is, in this modified game, also, the player who can first get a safe combination should win.

This modified game can also be generalized to any number of piles. The safe combinations are the same as before, except that an odd number of piles, each containing one, is now safe, while an even number of ones is not safe.