Perform this trick for a friend

Note: there are two other tricks on this site you can perform for a friend: Two minds together and Your Voice)

 

Pretend you are playing a game. Ask a friend pick any secret number from 1 to 63 and tell you which cards that number appears on. You immediately tell them the number they selected.

Here is how the trick is done: The key is the number in the upper left hand square of each card (1,2,4,8,16,32).  For example, your friend tells you their number is on cards 1,3,4. The upper left hand squares of those cards are numbered 1,4,8. Added together the total is 13. This is your friends "Secret Number".  Easy to do, hard to figure out how you did it!

To start the trick, click on the last letter (r) in Secret Number on the menu bar.

 

      1      
1 3 5 7 9 11 13
15 17 19 21 23 25 27
29 31 33 35 37 39 41
43 45 47 49 51 53 55
57 59 61 63      
      2      
2 3 6 7 10 11 14
15 18 19 22 23 26 27
30 31 34 35 38 39 42
43 46 47 50 51 54 55
58 59 62 63      
      3      
4 5 6 7 12 13 14
15 20 21 22 23 28 29
30 31 36 37 38 39 44
45 46 47 52 53 54 55
60 61 62 63      
      4      
8 9 10 11 12 13 14
15 24 25 26 27 28 29
30 31 40 41 42 43 44
46 46 47 56 57 58 59
60 61 62 63      
      5      
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 48 49 50 51 52
53 54 55 56 57 58 59
60 61 62 63      
      6      
32 33 34 35 36 37 38
39 40 41 42 43 44 45
46 47 48 49 50 51 52
53 54 55 56 57 58 59
60 61 62 63