## A magazine where the digital world meets the real world.

# On the web

- Home
- Browse by date
- Browse by topic
- Enter the maze
- Follow our blog
- Follow us on Twitter
- Resources for teachers
- Subscribe

# In print

# What is cs4fn?

- About us
- Contact us
- Partners
- Privacy and cookies
- Copyright and contributions
- Links to other fun sites
- Complete our questionnaire, give us feedback

# Search:

# The 21-card trick in detail

To get the trick to work you have to follow the instructions exactly. Trouble is with human languages the words sometimes aren't precise enough to be totally clear. That's why programming languages were invented - they are just languages with very precise meanings for giving instructions.

Just in case you are having trouble making it work, let's go through the instructions in a bit more detail and with pictures. It involves several deals, each apparently shuffling the order of the cards, but doing so in a rather cunning way.

## Deal Number 1

Deal 21 cards face up, left to right, into three equal piles of 7. We will show them unshufffled so you can see what happens.

Your friend is asked to mentally select any one of the 21 cards and tell you only which pile it is in. In this example we will assume the chosen card is the Queen of Hearts, though it works whatever is chosen. The piles are stacked so that the pile that contains your friend's chosen card is placed between the other two. This is really the most important move, but try and make it look casual when you are putting the piles together.

## Deal Number 2

The cards in this pile are now dealt out again left to right into three piles the cards in the first pile are now spread over the other piles by the process of dealing the cards again so their order now looks like this:

Once again, your friend is asked to find their chosen card and only tell you which pile it is in. The cards are collected up again in the same way as before, the new pile containing the chosen card is casually placed in between the other two piles (the same procedure as before).

## Deal Number 3

Deal the cards into 3 piles again for the third time; this will produce the following layout:

Again, the person is asked to say which pile contains their chosen card. In fact whichever pile they says it's in, look at the fourth (middle) card down in that pile. If you've done everything correctly up to this point, then their card will actually be there, wherever it was at the start! With one more deal we can move the card to the centre of the middle pile.

## Deal Number 4

So again the pile containing the card, in this case pile 1, is gathered up and oh so casually placed between piles 2 and 3, and the cards are dealt out into the now familiar three piles. The middle card of the middle pile is the chosen card, which you can reveal as you see fit.

# Abracadabra!

Of course the more interesting question is WHY does it work?