Saturday, May 28, 2011

Maths Magic

123456789 = 100


123456789 = 100

© Copyright 2003, Jim Loy
Puzzle: I received email asking me to make the numbers 123456789 add up to 100, by inserting any of these arithmetic operations (+ - * /) into the string of numbers (and keeping the numbers in the above order). I've seen this in a book somewhere, and I think the book gave only one solution. You might want to try it.

Solution: I found this solution by hand: 1+2+3-4+5+6+78+9, and my computer (with the standard computer rules of precendence, like 1/2*34 is 17) found all of these solutions:
1     123+45-67+8-9
         2     123+4-5+67-89
         3     123+4*5-6*7+8-9
         4     123-45-67+89
         5     123-4-5-6-7+8-9
         6     12+34+5*6+7+8+9
         7     12+34-5+6*7+8+9
         8     12+34-5-6+7*8+9
         9     12+34-5-6-7+8*9
        10     12+3+4+5-6-7+89
        11     12+3+4-56/7+89
        12     12+3-4+5+67+8+9
        13     12+3*45+6*7-89
        14     12+3*4+5+6+7*8+9
        15     12+3*4+5+6-7+8*9
        16     12+3*4-5-6+78+9
        17     12-3+4*5+6+7*8+9
        18     12-3+4*5+6-7+8*9
        19     12-3-4+5-6+7+89
        20     12-3-4+5*6+7*8+9
        21     12-3-4+5*6-7+8*9
        22     12*3-4+5-6+78-9
        23     12*3-4-5-6+7+8*9
        24     12*3-4*5+67+8+9
        25     12/3+4*5-6-7+89
        26     12/3+4*5*6-7-8-9
        27     12/3+4*5*6*7/8-9
        28     12/3/4+5*6+78-9
        29     1+234-56-7-8*9
        30     1+234*5*6/78+9
        31     1+234*5/6-7-89
        32     1+23-4+56+7+8+9
        33     1+23-4+56/7+8*9
        34     1+23-4+5+6+78-9
        35     1+23-4-5+6+7+8*9
        36     1+23*4+56/7+8-9
        37     1+23*4+5-6+7-8+9
        38     1+23*4-5+6+7+8-9
        39     1+2+34-5+67-8+9
        40     1+2+34*5+6-7-8*9
        41     1+2+3+4+5+6+7+8*9
        42     1+2+3-45+67+8*9
        43     1+2+3-4+5+6+78+9
        44     1+2+3-4*5+6*7+8*9
        45     1+2+3*4-5-6+7+89
        46     1+2+3*4*56/7-8+9
        47     1+2+3*4*5/6+78+9
        48     1+2-3*4+5*6+7+8*9
        49     1+2-3*4-5+6*7+8*9
        50     1+2*34-56+78+9
        51     1+2*3+4+5+67+8+9
        52     1+2*3+4*5-6+7+8*9
        53     1+2*3-4+56/7+89
        54     1+2*3-4-5+6+7+89
        55     1+2*3*4*5/6+7+8*9
        56     1-23+4*5+6+7+89
        57     1-23-4+5*6+7+89
        58     1-23-4-5+6*7+89
        59     1-2+3+45+6+7*8-9
        60     1-2+3*4+5+67+8+9
        61     1-2+3*4*5+6*7+8-9
        62     1-2+3*4*5-6+7*8-9
        63     1-2-34+56+7+8*9
        64     1-2-3+45+6*7+8+9
        65     1-2-3+45-6+7*8+9
        66     1-2-3+45-6-7+8*9
        67     1-2-3+4*56/7+8*9
        68     1-2-3+4*5+67+8+9
        69     1-2*3+4*5+6+7+8*9
        70     1-2*3-4+5*6+7+8*9
        71     1-2*3-4-5+6*7+8*9
        72     1*234+5-67-8*9
        73     1*23+4+56/7*8+9
        74     1*23+4+5+67-8+9
        75     1*23-4+5-6-7+89
        76     1*23-4-56/7+89
        77     1*23*4-56/7/8+9
        78     1*2+34+56+7-8+9
        79     1*2+34+5+6*7+8+9
        80     1*2+34+5-6+7*8+9
        81     1*2+34+5-6-7+8*9
        82     1*2+34-56/7+8*9
        83     1*2+3+45+67-8-9
        84     1*2+3+4*5+6+78-9
        85     1*2+3-4+5*6+78-9
        86     1*2+3*4+5-6+78+9
        87     1*2-3+4+56/7+89
        88     1*2-3+4-5+6+7+89
        89     1*2-3+4*5-6+78+9
        90     1*2*34+56-7-8-9
        91     1*2*3+4+5+6+7+8*9
        92     1*2*3-45+67+8*9
        93     1*2*3-4+5+6+78+9
        94     1*2*3-4*5+6*7+8*9
        95     1*2*3*4+5+6+7*8+9
        96     1*2*3*4+5+6-7+8*9
        97     1*2*3*4-5-6+78+9
        98     1*2/3+4*5/6+7+89
        99     1/2*34-5+6-7+89
       100     1/2*3/4*56+7+8*9
       101     1/2/3*456+7+8+9
The shortest solution (fewest operations) is 123-45-67+89. There are 15 solutions with no two-digit or three-digit numbers. There are more solutions, if a negative sign (which is different from subtraction) is allowed. Allowing parentheses would produce a lot more solutions. There are quite a few longest solutions, with nine operations.

Addendum:
A reader sent this email:
I send out a daily brainteaser to my group here at work and one of my co-workers came up with a new solution to your 123456789=100 puzzle. Just thought you'd like to know. 1 * 2 + 3 * 4 * 5 + 6 - 7 - 8 + 9 = 100!
1*2+3*4*5+6-7-8+9 does not come out to 100, if it is viewed as a mathematical expression, because multiplication (or division) has precedence over addition or subtraction. We do the multiplication first, and then the addition and/or subtraction last. We mainly see this in algebra [where a+bc is a+(bc) and not (a+b)c] and in computer programming in BASIC and other languages (there are also languages with different kinds of precedence).
But this sequence of numbers and operations can also be viewed as a sequence of calculator key strokes, performed absolutely left to right, in which case it does come out to 100 (but not on my two scientific calculators). Most of my solutions above do not come out to 100 if done left to right. In my view, 1*2+3*4*5+6-7-8+9 does not indicate key strokes, but is a mathematical expression, and it requires a pair of parentheses to come out right: (1*2+3)*4*5+6-7-8+9 = 100.
With that warning about precedence, some people may still find some of my solutions confusing, like 1/2*3/4*56+7+8*9. Since multiplication and division have the same precedence, we evaluate them left to right, and so there is no problem. But some people may see the 2*3 as being a denominator. Similarly, with 1/2/3*456+7+8+9, some people may see the 2/3 as a denominator. But the most common standard is to do these divisions left to right.

A woman sent me this puzzle: _/_*_+_*_*_/_+_*_ = 100. Fill in the blanks with the digits 1 through 9 in any order. From the way it was described to me, ignore the rules of operator precedence, and just perform the operations from left to right. Thus, this works on the simplest of calculators, but will probably fail on some scientific calculators (unless you press = or ENTER after each digit). There are, of course, 362,880 ways to arrange these nine digits, and here are the 199 solutions:
1 1/2*7+5*3*6/9+8*4
         2 1/2*7+5*6*3/9+8*4
         3 1/2*8+5*3*6/9+7*4
         4 1/2*8+5*6*3/9+7*4
         5 1/3*6+5*2*8/7+9*4
         6 1/3*6+5*8*2/7+9*4
         7 1/3*6+7*2*8/9+4*5
         8 1/3*6+7*8*2/9+4*5
         9 1/3*8+9*2*6/7+5*4
        10 1/3*8+9*6*2/7+5*4
        11 1/3*9+4*2*6/7+8*5
        12 1/3*9+4*6*2/7+8*5
        13 1/4*7+2*3*6/9+5*8
        14 1/4*7+2*6*3/9+5*8
        15 1/4*8+7*3*6/9+2*5
        16 1/4*8+7*6*3/9+2*5
        17 1/6*2+5*3*9/8+7*4
        18 1/6*2+5*9*3/8+7*4
        19 1/6*2+7*3*4/8+9*5
        20 1/6*2+7*4*3/8+9*5
        21 1/6*8+2*3*9/5+7*4
        22 1/6*8+2*9*3/5+7*4
        23 1/9*3+2*6*8/7+4*5
        24 1/9*3+2*8*6/7+4*5
        25 1/9*5+8*3*4/7+2*6
        26 1/9*5+8*4*3/7+2*6
        27 1/9*6+8*2*3/4+7*5
        28 1/9*6+8*3*2/4+7*5
        29 1/9*7+5*2*3/4+8*6
        30 1/9*7+5*3*2/4+8*6
        31 1/9*8+2*3*6/4+7*5
        32 1/9*8+2*6*3/4+7*5
        33 2/3*5+6*8*9/7+4*1
        34 2/3*5+6*9*8/7+4*1
        35 2/4*8+1*3*7/9+5*6
        36 2/4*8+1*7*3/9+5*6
        37 2/6*1+5*3*9/8+7*4
        38 2/6*1+5*9*3/8+7*4
        39 2/6*1+7*3*4/8+9*5
        40 2/6*1+7*4*3/8+9*5
        41 2/6*7+1*3*8/5+9*4
        42 2/6*7+1*8*3/5+9*4
        43 2/6*7+3*1*9/4+8*5
        44 2/6*7+3*9*1/4+8*5
        45 2/6*9+7*1*3/4+5*8
        46 2/6*9+7*3*1/4+5*8
        47 2/8*9+5*1*4/3+7*6
        48 2/8*9+5*4*1/3+7*6
        49 2/9*3+8*1*6/4+7*5
        50 2/9*3+8*6*1/4+7*5
        51 3/2*5+8*4*9/6+7*1
        52 3/2*5+8*9*4/6+7*1
        53 3/2*6+5*1*8/7+9*4
        54 3/2*6+5*8*1/7+9*4
        55 3/4*9+2*1*6/7+5*8
        56 3/4*9+2*6*1/7+5*8
        57 3/6*7+2*1*8/4+9*5
        58 3/6*7+2*8*1/4+9*5
        59 3/6*8+1*2*9/5+7*4
        60 3/6*8+1*9*2/5+7*4
        61 3/6*9+2*1*8/4+7*5
        62 3/6*9+2*8*1/4+7*5
        63 3/9*1+2*6*8/7+4*5
        64 3/9*1+2*8*6/7+4*5
        65 3/9*2+8*1*6/4+7*5
        66 3/9*2+8*6*1/4+7*5
        67 3/9*5+2*1*6/4+7*8
        68 3/9*5+2*6*1/4+7*8
        69 3/9*6+5*7*8/4+2*1
        70 3/9*6+5*8*7/4+2*1
        71 3/9*6+7*1*8/4+2*5
        72 3/9*6+7*8*1/4+2*5
        73 3/9*7+5*1*8/4+2*6
        74 3/9*7+5*8*1/4+2*6
        75 4/2*7+8*1*3/6+9*5
        76 4/2*7+8*3*1/6+9*5
        77 4/2*9+8*1*3/6+7*5
        78 4/2*9+8*3*1/6+7*5
        79 4/3*9+2*1*6/7+8*5
        80 4/3*9+2*6*1/7+8*5
        81 4/8*7+2*1*6/3+9*5
        82 4/8*7+2*6*1/3+9*5
        83 4/8*9+2*1*6/3+7*5
        84 4/8*9+2*6*1/3+7*5
        85 5/2*3+8*4*9/6+7*1
        86 5/2*3+8*9*4/6+7*1
        87 5/3*2+6*8*9/7+4*1
        88 5/3*2+6*9*8/7+4*1
        89 5/3*9+7*1*8/4+6*2
        90 5/3*9+7*8*1/4+6*2
        91 5/4*6+8*2*9/3+7*1
        92 5/4*6+8*9*2/3+7*1
        93 5/4*7+1*2*3/9+6*8
        94 5/4*7+1*3*2/9+6*8
        95 5/6*7+1*3*8/4+9*2
        96 5/6*7+1*8*3/4+9*2
        97 5/6*9+3*2*8/7+1*4
        98 5/6*9+3*8*2/7+1*4
        99 5/6*9+8*3*4/2+7*1
       100 5/6*9+8*4*3/2+7*1
       101 5/9*1+8*3*4/7+2*6
       102 5/9*1+8*4*3/7+2*6
       103 5/9*3+2*1*6/4+7*8
       104 5/9*3+2*6*1/4+7*8
       105 6/2*3+5*1*8/7+9*4
       106 6/2*3+5*8*1/7+9*4
       107 6/2*9+7*1*4/8+3*5
       108 6/2*9+7*4*1/8+3*5
       109 6/3*1+5*2*8/7+9*4
       110 6/3*1+5*8*2/7+9*4
       111 6/3*1+7*2*8/9+4*5
       112 6/3*1+7*8*2/9+4*5
       113 6/3*7+8*1*2/4+9*5
       114 6/3*7+8*2*1/4+9*5
       115 6/3*9+8*1*2/4+7*5
       116 6/3*9+8*2*1/4+7*5
       117 6/4*5+8*2*9/3+7*1
       118 6/4*5+8*9*2/3+7*1
       119 6/9*1+8*2*3/4+7*5
       120 6/9*1+8*3*2/4+7*5
       121 6/9*3+5*7*8/4+2*1
       122 6/9*3+5*8*7/4+2*1
       123 6/9*3+7*1*8/4+2*5
       124 6/9*3+7*8*1/4+2*5
       125 7/2*1+5*3*6/9+8*4
       126 7/2*1+5*6*3/9+8*4
       127 7/2*4+8*1*3/6+9*5
       128 7/2*4+8*3*1/6+9*5
       129 7/2*8+5*1*6/9+3*4
       130 7/2*8+5*6*1/9+3*4
       131 7/3*6+8*1*2/4+9*5
       132 7/3*6+8*2*1/4+9*5
       133 7/4*1+2*3*6/9+5*8
       134 7/4*1+2*6*3/9+5*8
       135 7/4*5+1*2*3/9+6*8
       136 7/4*5+1*3*2/9+6*8
       137 7/4*9+8*2*6/3+5*1
       138 7/4*9+8*6*2/3+5*1
       139 7/6*2+1*3*8/5+9*4
       140 7/6*2+1*8*3/5+9*4
       141 7/6*2+3*1*9/4+8*5
       142 7/6*2+3*9*1/4+8*5
       143 7/6*3+2*1*8/4+9*5
       144 7/6*3+2*8*1/4+9*5
       145 7/6*5+1*8*3/4+9*2
       146 7/8*4+2*1*6/3+9*5
       147 7/8*4+2*6*1/3+9*5
       148 7/9*1+5*2*3/4+8*6
       149 7/9*1+5*3*2/4+8*6
       150 7/9*3+5*1*8/4+2*6
       151 7/9*3+5*8*1/4+2*6
       152 8/2*1+5*3*6/9+7*4
       153 8/2*1+5*6*3/9+7*4
       154 8/2*7+5*1*6/9+3*4
       155 8/2*7+5*6*1/9+3*4
       156 8/3*1+9*2*6/7+5*4
       157 8/3*1+9*6*2/7+5*4
       158 8/4*1+7*3*6/9+2*5
       159 8/4*1+7*6*3/9+2*5
       160 8/4*2+1*3*7/9+5*6
       161 8/4*2+1*7*3/9+5*6
       162 8/4*9+3*1*6/7+2*5
       163 8/4*9+3*6*1/7+2*5
       164 8/6*1+2*3*9/5+7*4
       165 8/6*1+2*9*3/5+7*4
       166 8/6*3+1*2*9/5+7*4
       167 8/6*3+1*9*2/5+7*4
       168 8/9*1+2*3*6/4+7*5
       169 8/9*1+2*6*3/4+7*5
       170 9/2*4+8*1*3/6+7*5
       171 9/2*4+8*3*1/6+7*5
       172 9/2*6+7*1*4/8+3*5
       173 9/2*6+7*4*1/8+3*5
       174 9/3*1+4*2*6/7+8*5
       175 9/3*1+4*6*2/7+8*5
       176 9/3*4+2*1*6/7+8*5
       177 9/3*4+2*6*1/7+8*5
       178 9/3*5+7*1*8/4+6*2
       179 9/3*5+7*8*1/4+6*2
       180 9/3*6+8*1*2/4+7*5
       181 9/3*6+8*2*1/4+7*5
       182 9/4*3+2*1*6/7+5*8
       183 9/4*3+2*6*1/7+5*8
       184 9/4*7+8*2*6/3+5*1
       185 9/4*7+8*6*2/3+5*1
       186 9/4*8+3*1*6/7+2*5
       187 9/4*8+3*6*1/7+2*5
       188 9/6*2+7*1*3/4+5*8
       189 9/6*2+7*3*1/4+5*8
       190 9/6*3+2*1*8/4+7*5
       191 9/6*3+2*8*1/4+7*5
       192 9/6*5+3*2*8/7+1*4
       193 9/6*5+3*8*2/7+1*4
       194 9/6*5+8*3*4/2+7*1
       195 9/6*5+8*4*3/2+7*1
       196 9/8*2+5*1*4/3+7*6
       197 9/8*2+5*4*1/3+7*6
       198 9/8*4+2*1*6/3+7*5
       199 9/8*4+2*6*1/3+7*5
No decent puzzle composer would poze a problem which has 199 solutions.

I reported the above solutions to the above-mentioned woman, and she informed me that the rules of operator precendence DO apply to this puzzle, and then she became somewhat insulting (as seems to happen a lot on the Internet). Here are the 192 solutions, in that case, which I did not send to her:
1 1/2*6+5*7*8/4+3*9
         2 1/2*6+5*7*8/4+9*3
         3 1/2*6+5*8*7/4+3*9
         4 1/2*6+5*8*7/4+9*3
         5 1/2*6+7*5*8/4+3*9
         6 1/2*6+7*5*8/4+9*3
         7 1/2*6+7*8*5/4+3*9
         8 1/2*6+7*8*5/4+9*3
         9 1/2*6+8*5*7/4+3*9
        10 1/2*6+8*5*7/4+9*3
        11 1/2*6+8*7*5/4+3*9
        12 1/2*6+8*7*5/4+9*3
        13 4/1*8+2*3*5/6+7*9
        14 4/1*8+2*3*5/6+9*7
        15 4/1*8+2*5*3/6+7*9
        16 4/1*8+2*5*3/6+9*7
        17 4/1*8+3*2*5/6+7*9
        18 4/1*8+3*2*5/6+9*7
        19 4/1*8+3*5*2/6+7*9
        20 4/1*8+3*5*2/6+9*7
        21 4/1*8+5*2*3/6+7*9
        22 4/1*8+5*2*3/6+9*7
        23 4/1*8+5*3*2/6+7*9
        24 4/1*8+5*3*2/6+9*7
        25 4/6*9+2*5*7/1+3*8
        26 4/6*9+2*5*7/1+8*3
        27 4/6*9+2*7*5/1+3*8
        28 4/6*9+2*7*5/1+8*3
        29 4/6*9+5*2*7/1+3*8
        30 4/6*9+5*2*7/1+8*3
        31 4/6*9+5*7*2/1+3*8
        32 4/6*9+5*7*2/1+8*3
        33 4/6*9+7*2*5/1+3*8
        34 4/6*9+7*2*5/1+8*3
        35 4/6*9+7*5*2/1+3*8
        36 4/6*9+7*5*2/1+8*3
        37 4/8*6+2*5*7/1+3*9
        38 4/8*6+2*5*7/1+9*3
        39 4/8*6+2*7*5/1+3*9
        40 4/8*6+2*7*5/1+9*3
        41 4/8*6+5*2*7/1+3*9
        42 4/8*6+5*2*7/1+9*3
        43 4/8*6+5*7*2/1+3*9
        44 4/8*6+5*7*2/1+9*3
        45 4/8*6+7*2*5/1+3*9
        46 4/8*6+7*2*5/1+9*3
        47 4/8*6+7*5*2/1+3*9
        48 4/8*6+7*5*2/1+9*3
        49 6/2*1+5*7*8/4+3*9
        50 6/2*1+5*7*8/4+9*3
        51 6/2*1+5*8*7/4+3*9
        52 6/2*1+5*8*7/4+9*3
        53 6/2*1+7*5*8/4+3*9
        54 6/2*1+7*5*8/4+9*3
        55 6/2*1+7*8*5/4+3*9
        56 6/2*1+7*8*5/4+9*3
        57 6/2*1+8*5*7/4+3*9
        58 6/2*1+8*5*7/4+9*3
        59 6/2*1+8*7*5/4+3*9
        60 6/2*1+8*7*5/4+9*3
        61 6/2*9+5*7*8/4+1*3
        62 6/2*9+5*7*8/4+3*1
        63 6/2*9+5*8*7/4+1*3
        64 6/2*9+5*8*7/4+3*1
        65 6/2*9+7*5*8/4+1*3
        66 6/2*9+7*5*8/4+3*1
        67 6/2*9+7*8*5/4+1*3
        68 6/2*9+7*8*5/4+3*1
        69 6/2*9+8*5*7/4+1*3
        70 6/2*9+8*5*7/4+3*1
        71 6/2*9+8*7*5/4+1*3
        72 6/2*9+8*7*5/4+3*1
        73 6/8*4+2*5*7/1+3*9
        74 6/8*4+2*5*7/1+9*3
        75 6/8*4+2*7*5/1+3*9
        76 6/8*4+2*7*5/1+9*3
        77 6/8*4+5*2*7/1+3*9
        78 6/8*4+5*2*7/1+9*3
        79 6/8*4+5*7*2/1+3*9
        80 6/8*4+5*7*2/1+9*3
        81 6/8*4+7*2*5/1+3*9
        82 6/8*4+7*2*5/1+9*3
        83 6/8*4+7*5*2/1+3*9
        84 6/8*4+7*5*2/1+9*3
        85 7/1*9+2*3*5/6+4*8
        86 7/1*9+2*3*5/6+8*4
        87 7/1*9+2*5*3/6+4*8
        88 7/1*9+2*5*3/6+8*4
        89 7/1*9+3*2*5/6+4*8
        90 7/1*9+3*2*5/6+8*4
        91 7/1*9+3*5*2/6+4*8
        92 7/1*9+3*5*2/6+8*4
        93 7/1*9+5*2*3/6+4*8
        94 7/1*9+5*2*3/6+8*4
        95 7/1*9+5*3*2/6+4*8
        96 7/1*9+5*3*2/6+8*4
        97 7/4*8+3*6*9/2+1*5
        98 7/4*8+3*6*9/2+5*1
        99 7/4*8+3*9*6/2+1*5
       100 7/4*8+3*9*6/2+5*1
       101 7/4*8+6*3*9/2+1*5
       102 7/4*8+6*3*9/2+5*1
       103 7/4*8+6*9*3/2+1*5
       104 7/4*8+6*9*3/2+5*1
       105 7/4*8+9*3*6/2+1*5
       106 7/4*8+9*3*6/2+5*1
       107 7/4*8+9*6*3/2+1*5
       108 7/4*8+9*6*3/2+5*1
       109 8/1*4+2*3*5/6+7*9
       110 8/1*4+2*3*5/6+9*7
       111 8/1*4+2*5*3/6+7*9
       112 8/1*4+2*5*3/6+9*7
       113 8/1*4+3*2*5/6+7*9
       114 8/1*4+3*2*5/6+9*7
       115 8/1*4+3*5*2/6+7*9
       116 8/1*4+3*5*2/6+9*7
       117 8/1*4+5*2*3/6+7*9
       118 8/1*4+5*2*3/6+9*7
       119 8/1*4+5*3*2/6+7*9
       120 8/1*4+5*3*2/6+9*7
       121 8/3*9+4*5*7/2+1*6
       122 8/3*9+4*5*7/2+6*1
       123 8/3*9+4*7*5/2+1*6
       124 8/3*9+4*7*5/2+6*1
       125 8/3*9+5*4*7/2+1*6
       126 8/3*9+5*4*7/2+6*1
       127 8/3*9+5*7*4/2+1*6
       128 8/3*9+5*7*4/2+6*1
       129 8/3*9+7*4*5/2+1*6
       130 8/3*9+7*4*5/2+6*1
       131 8/3*9+7*5*4/2+1*6
       132 8/3*9+7*5*4/2+6*1
       133 8/4*7+3*6*9/2+1*5
       134 8/4*7+3*6*9/2+5*1
       135 8/4*7+3*9*6/2+1*5
       136 8/4*7+3*9*6/2+5*1
       137 8/4*7+6*3*9/2+1*5
       138 8/4*7+6*3*9/2+5*1
       139 8/4*7+6*9*3/2+1*5
       140 8/4*7+6*9*3/2+5*1
       141 8/4*7+9*3*6/2+1*5
       142 8/4*7+9*3*6/2+5*1
       143 8/4*7+9*6*3/2+1*5
       144 8/4*7+9*6*3/2+5*1
       145 9/1*7+2*3*5/6+4*8
       146 9/1*7+2*3*5/6+8*4
       147 9/1*7+2*5*3/6+4*8
       148 9/1*7+2*5*3/6+8*4
       149 9/1*7+3*2*5/6+4*8
       150 9/1*7+3*2*5/6+8*4
       151 9/1*7+3*5*2/6+4*8
       152 9/1*7+3*5*2/6+8*4
       153 9/1*7+5*2*3/6+4*8
       154 9/1*7+5*2*3/6+8*4
       155 9/1*7+5*3*2/6+4*8
       156 9/1*7+5*3*2/6+8*4
       157 9/2*6+5*7*8/4+1*3
       158 9/2*6+5*7*8/4+3*1
       159 9/2*6+5*8*7/4+1*3
       160 9/2*6+5*8*7/4+3*1
       161 9/2*6+7*5*8/4+1*3
       162 9/2*6+7*5*8/4+3*1
       163 9/2*6+7*8*5/4+1*3
       164 9/2*6+7*8*5/4+3*1
       165 9/2*6+8*5*7/4+1*3
       166 9/2*6+8*5*7/4+3*1
       167 9/2*6+8*7*5/4+1*3
       168 9/2*6+8*7*5/4+3*1
       169 9/3*8+4*5*7/2+1*6
       170 9/3*8+4*5*7/2+6*1
       171 9/3*8+4*7*5/2+1*6
       172 9/3*8+4*7*5/2+6*1
       173 9/3*8+5*4*7/2+1*6
       174 9/3*8+5*4*7/2+6*1
       175 9/3*8+5*7*4/2+1*6
       176 9/3*8+5*7*4/2+6*1
       177 9/3*8+7*4*5/2+1*6
       178 9/3*8+7*4*5/2+6*1
       179 9/3*8+7*5*4/2+1*6
       180 9/3*8+7*5*4/2+6*1
       181 9/6*4+2*5*7/1+3*8
       182 9/6*4+2*5*7/1+8*3
       183 9/6*4+2*7*5/1+3*8
       184 9/6*4+2*7*5/1+8*3
       185 9/6*4+5*2*7/1+3*8
       186 9/6*4+5*2*7/1+8*3
       187 9/6*4+5*7*2/1+3*8
       188 9/6*4+5*7*2/1+8*3
       189 9/6*4+7*2*5/1+3*8
       190 9/6*4+7*2*5/1+8*3
       191 9/6*4+7*5*2/1+3*8
       192 9/6*4+7*5*2/1+8*3

Number Magic


Number Magic

© Copyright 2002, Jim Loy
A few number magic tricks:
1. Pick a number, add 2, multiply by 3, subtract 6, divide by 3. You get the number you started with.
This works for other, larger numbers. I started with add 2 and multiply 3. But any two numbers work, just multiply them together to get the next number that you subtract.
2. Pick a number, square it (probably need a calculator for big numbers), add twice the original number, add one, take the square root (rounding it to the nearest whole number, 7.999... becomes 8), subtract 1, you get the number you started with. I made that one up.
These can be made into number guessing games. In the first one, don't have them divide by three at the end. Just have them tell you the answer and you can guess the original number by dividing by three. In that case, you may want many more steps, in order to make it more impressive and so they won't think that you just did the same arithmetic that they did, but backwards. Here is something like that:
3. Pick a number, multiply by 5, add 6, multiply by 4, add 9, multiply by 5, tell me the number you got there, I then tell you your original number.
Or you can make the steps come out to the same number every time. Here is an improved version of that second one. Just say, "I'll bet your answer is on this piece of paper" which you wrote the answer 5 on already:
4. Pick a number, square it, add ten times the original number, add 25, take the square root (rounding to the nearest whole number), subtract your original number. I'll bet your answer is 5.
5. Here's a more complicated one from Brain Boosters: Pick number between 1 and 100, add 28, multiply by 6, subtract 3, divide by 3, subtract the original number plus 3, add 8, subtract the original number minus 1, multiply by 7. Your answer was 427.
Other number magic:
6. Use a calculator for this one: Pick a number 1 through 9, multiply by 12345679 (notice there is no 8 there), multiply by 9. Do you see your original number?
7. You write a number with 5 digits, maybe 38725 I write a number below that, like 61274 You write a 5-digit number below that, like 16391 I write a number below that, like 83608 You write a 5-digit number below that, like 67321 I then draw a line below that and write the sum, 267319 Someone verifies this answer with a calculator.
8. Pick a 3-digit number in which the first and last digits differ by more than one, reverse this number (531 becomes 135) and subtract the smaller from the larger, add this number to the reverse of itself. I'll bet your answer is 1089.
9. I received this in my email (I modified it slightly): Pick a number (one to three digits probably), add 5, multiply by 3, square this number, add the digits over and over until you get only one digit (i.e. 64=6+4=10=1+0=1), if the number is less than 5 then add five otherwise subtract 4, multiply by 2, subtract 6, use this number to select a letter of the alphabet 1=A, 2=B, 3=C, etc., pick the name of a country that begins with that letter, take the second letter in the country name and think of an animal that begins with that letter, but there are no elephants in Denmark!
I added 5 instead of subtracting 5. And the original limited the original number to 1 through 9, which is unnecessary. Some people might pick Dominican Republic, or an even more exotic country, or a more exotic animal.
10. Here is collection of seven cards which you may have seen (the numbers on the cards often go up to 127 or so):
first card second card
third card fourth card
fifth card sixth card
seventh card
Pick a number from 1 to 100. I then show you each card, one at a time, and ask, "Is your number on this card?" After I have shown you all seven cards, I then tell you your number. Other collections of cards also work, but are less efficient (require more cards for 1-100).
See Super Brain.

How they work:
You may want to try to figure out how the above tricks work, before reading further.
1. Pick a number, add 2, multiply by 3, subtract 6, divide by 3. You get the number you started with.
Converting to an algebraic expression: (3(x+2)-6)/3, which is x.
2. Pick a number, square it (probably need a calculator for big numbers), add twice the original number, add one, take the square root (rounding it to the nearest whole number, 7.999... becomes 8), subtract 1, you get the number you started with. I made that one up. Other squaring formulas work.
The expression before taking the square root is x^2+2x+1, which is a perfect square. The square root is x+1, we subtract 1, and get x.
3. Pick a number, multiply by 5, add 6, multiply by 4, add 9, multiply by 5, tell me the number you got there, I then tell you your original number.
This is 5(4(5x+6)+9), which is 100x+165. So, to guess your number I subtract 165 (easy as your answer ends in . . . 65) and divide by 100.
4. Pick a number, square it, add ten times the original number, add 25, take the square root (rounding to the nearest whole number), subtract your original number. I'll bet your answer is 5.
Before we take the square root, we have x^2+10x+25, which is a perfect square. The square root is x+5; we subtract x, and get 5.
5. Here's a more complicated one from Brain Boosters: Pick number between 1 and 100, add 28, multiply by 6, subtract 3, divide by 3, subtract the original number plus 3, add 8, subtract the original number minus 1, multiply by 7. Your answer was 427.
Here the many steps are simple, and we subtract out the original number until it is gone, and 427 is what is left.
6. Use a calculator for this one: Pick a number 1 through 9, multiply by 12345679 (notice there is no 8 there), multiply by 9. Do you see your original number?
12345679x9 is coincidentally 111111111. Our single-digit number times this is that digit repeated nine times.
7. You write a number with 5 digits, maybe 38725 I write a number below that, like 61274 You write a 5-digit number below that, like 16391 I write a number below that, like 83608 You write a 5-digit number below that, like 67321 I then draw a line below that and write the sum, 267319 Someone verifies this answer with a calculator.
The numbers that I wrote were 99999-whatever number you wrote (easy to do). So I just added 200000 to your last number, and subtracted 2. You can do this with numbers with more digits.
8. Pick a 3-digit number in which the first and last digits differ by more than one, reverse this number (531 becomes 135) and subtract the smaller from the larger, add this number to the reverse of itself. I'll bet your answer is 1089.
I guess we have to stipulate that the first and last digits must differ by more than one, so we ever don't end up with a zero as the left digit, which would complicate matters. Here is our number (pretend that x>z): 100x+10y+z. We reverse and subtract: 100(x-z-1)+90+(10-x+z). The reverse of this is 100(10-x+z)+90+(x-z-1). Adding, we get 1089.
9. I received this in my email (I modified it slightly): Pick a number (one to three digits probably), add 5, multiply by 3, square this number, add the digits over and over until you get only one digit (i.e. 64=6+4=10=1+0=1), if the number is less than 5 then add five otherwise subtract 4, multiply by 2, subtract 6, use this number to select a letter of the alphabet 1=A, 2=B, 3=C, etc., pick the name of a country that begins with that letter, take the second letter in the country name and think of an animal that begins with that letter, but there are no elephants in Denmark!
This looks a little mysterious, until we see that we multiplied by 3 and then squared, so after squaring we have a multiple of 9, and we don't care what it is. Adding the digits over and over is called Casting Out Nines. Since our number is a multiple of 9, repeated adding of the digits should give us 9 (or 0). Subtract 4, multiply by 2, subtract 6 gives us 4, which maps with D. We are likely to guess Denmark, and elephant.
10. Here is collection of seven cards which you may have seen (the numbers on the cards often go up to 127 or so):
first card second card
third card fourth card
fifth card sixth card
seventh card
Pick a number from 1 to 100. I then show you each card, one at a time, and ask, "Is your number on this card?" After I have shown you all seven cards, I then tell you your number. Other collections of cards also work, but are less efficient (require more cards for 1-100).
This is just a translation of your secret number to or from binary (base-2) form. If your number is on the seventh card, I notice that that card has a 64 in the upper left corner, and I remember that 64 (otherwise I remember 0). If your number is on the sixth card, I add 32 to the previous number, etc. Let's say your number was 37. It's not on the seventh card, it is on the sixth (total = 32). It is on the third card (total=36), and it is on the first card (total=37). Your number is 37. So, why did that work? Well, the seventh card lists all numbers from 1 to 100 in which the seventh binary digit (64) is 1. The sixth card lists all numbers in which the sixth binary digit (32) is 1, etc. Adding up these numbers (32+4+1 in the case of 37) is exactly how we convert from binary to decimal.