# The Tic-Tac-Toe Magic Square trick

In Mathematics Magic and Mystery by Martin Gardner, the author presents an interesting card trick to create a magic square (where all rows and columns add to the same number), using an interesting interactive game with a participant. After playing a game of tic-tac-toe, your friends will be surprised to see they set up the cards in a 3×3 grid summing the number on the cards to 15!

## Implementing the card-trick

To start off, the deck should have 9 cards, in increasing order except for the first 4:

A, 8,2,7,3,4,5,6,9

where Ace is “1”. You can put these on top of the deck and have it shuffled, they should be in the same order and you can pick out all of this suit out of the deck and in this order.

Next put the 5 in the middle of the tic tac toe board (face down), asking for opponent’s first choice of move. If it is a corner, move 6,9 to the top of the deck (above A) otherwise keep it there – A,8,2,7,3,4,6,9 will be the drawing order.

Draw the top and place it where your opponent marked, and place the deck down. Now you add one (face down) to the tic tac toe board in the pattern that will make 15 the sum in each row and column. This is not the usual strategy of winning as this should end in a draw and you are trying to force certain cards to the appropriate spot so that all 9 spaces will have the right card. If you do it right it works!

The book suggests that if they choose a corner, “play on either side of the corner diagonally opposite”. Otherwise, after a side item is chosen – “play on the corner on either side of his play”. After this of course you can continue placing your card you draw in the place where it will fit the pattern of 15 for row, columns, and diagonal.

The resulting square should look like this when finished…

## Key takeaways

The lesson that goes along with this trick goes along with something many of us learned years ago – that the first person to play in Tictactoe gets an advantage, and could win or at least draw. With this version of the game one can force a draw and force the same type of game state, with magic-square condition again and again!

The initial shuffle and set down in one of two different ways lets you control what your opponent draws, and every other draw through the game, though they may not notice it because you just set the “shuffled” deck down after you ask where they want to play ðŸ™‚ Sort of a sleight of hand.

There has been much written about magic squares elsewhere – See Wolfram’s article and DurangoBill’s review of various squares for example.