Math Lab
Home/Class VIII/Ch 5/Cryptarithms and challenges

Cryptarithms and challenges

A cryptarithm is an arithmetic puzzle where the digits have been replaced by letters. Each letter stands for a distinct digit. Your job: figure out the digits so the arithmetic works. They are exactly as old as written arithmetic and still appear in newspapers today.

Concept

The most famous example is

  S E N D
+ M O R E
---------
M O N E Y

Each letter is one of 0,1,,90, 1, \dots, 9. Different letters stand for different digits. Solve!

Strategy 1: Carry analysis. Look at the leftmost column. Adding two single digits (each 9\le 9) gives at most 9+9+1=199 + 9 + 1 = 19. So the leftmost column has at most a carry of 11. In the above puzzle, S+M=MO+10carryS + M = MO + 10\cdot \text{carry}, where the leading MM of the answer must come from a carry. So M=1M = 1.

Strategy 2: Use the units column. The rightmost letters tell you the last digit of the sum directly (possibly with a carry to the next column).

Strategy 3: Distinct digits constraint. Often you can rule out a letter being a particular digit because another letter has already claimed it.

For SEND + MORE = MONEY the unique solution (which you can find with some work) is:

S=9,E=5,N=6,D=7,M=1,O=0,R=8,Y=2.S = 9, E = 5, N = 6, D = 7, M = 1, O = 0, R = 8, Y = 2.

Verify: 9567+1085=106529567 + 1085 = 10652. ✓

Strategy for any cryptarithm.

  1. Identify any letter forced to be 11 (leading digit appearing as carry).
  2. Identify any letter forced to be 00 (when adding two columns gives the same letter back, with a carry).
  3. Use the units column to constrain a small set of possibilities.
  4. Try those possibilities; check consistency with other columns.

Another classic.

  A B C
+ A B C
+ A B C
+ A B C
-------
  B B B B

Translating: 4×(3-digit ABC)=(4-digit BBBB)4 \times \text{(3-digit ABC)} = \text{(4-digit BBBB)}. So 4×ABC=BBBB=B11114 \times \overline{ABC} = \overline{BBBB} = B \cdot 1111. The right side is B×1111B \times 1111 which is between 11111111 and 99999999. The left side is 4×ABC4 \times \overline{ABC} which is between 400400 and 39963996. So B11113996B \cdot 1111 \le 3996, giving B3B \le 3. And ABC=B11114\overline{ABC} = \dfrac{B \cdot 1111}{4}; we need this to be a whole number with A=BA = B? Let's check B=1B = 1: ABC=1111/4\overline{ABC} = 1111/4, not integer. B=2B = 2: 2222/4=555.52222/4 = 555.5, not integer. B=3B = 3? Hmm , this puzzle needs more constraint or it has no solution; cryptarithms are problem-specific.

Why this is good practice. Cryptarithms force you to think in modular and digit-by-digit ways. They use every divisibility and place-value idea from this chapter. Solving them is a strong test of the toolkit.

Worked examples

Example 1. Solve:

  A B
+ B A
-----
  C C
  • AB+BA=(10A+B)+(10B+A)=11(A+B)\overline{AB} + \overline{BA} = (10A + B) + (10B + A) = 11(A+B).
  • CC=11C\overline{CC} = 11 C.
  • So 11(A+B)=11C11(A+B) = 11C, giving C=A+BC = A + B.
  • For example, A=2,B=5,C=7A = 2, B = 5, C = 7: 25+52=7725 + 52 = 77. ✓

Example 2. Find a digit XX so that

  X X X
+ X X X
-------
  6 6 6
  • 2XXX=6662 \cdot \overline{XXX} = 666, so XXX=333\overline{XXX} = 333.
  • X=3X = 3. ✓

Example 3. Solve:

  A 1
\times  B
-----
  9 A

(Multiplication, not addition.) A1×B=9A\overline{A1} \times B = \overline{9A}, so (10A+1)B=90+A(10A + 1) B = 90 + A, i.e., 10AB+B=90+A10AB + B = 90 + A, so A(10B1)=90BA(10B - 1) = 90 - B. Try B=9B = 9: A89=81A \cdot 89 = 81, not integer. B=5B = 5: A49=85A \cdot 49 = 85, not. B=3B = 3: A29=87A \cdot 29 = 87, so A=3A = 3. Check: 31×3=9331 \times 3 = 93. ✓ So A=3,B=3A = 3, B = 3. But letters should be distinct usually , this puzzle does not have that constraint here.

Example 4. Solve AB×9=BAAB\overline{AB} \times 9 = \overline{BA}\overline{AB} (a 4-digit number whose first two are BA and last two are AB)?

This is harder; skip if time-pressed. Most class VIII cryptarithms only use addition.

Try it yourself

Solve each cryptarithm. Different letters represent different digits unless otherwise noted.

  1. A+A=B4A + A = B \cdot 4, with A,BA, B single digits.
  2.   B A
    + B A
    -----
      C A C
    
  3.   1 A
    + 2 B
    -----
      A B
    
  4. A B C
    \times 3
    -----
    B C A
    
  5. T E N
    - O N E
    -----
    T W O
    
    (Not all puzzles have solutions; show whether this one does.)
  6. Find the magic sum if a 5×55\times 5 magic square uses 11-2525.
  7.   A
    + B
    -----
    A A
    
    What does AA equal?
  8.   X Y Z
    + X Y Z
    -------
      Y Z Z 0
    
    Find X,Y,ZX, Y, Z (this one has multiple steps).

Activity / Insight

Cryptarithm club. With a friend, take turns inventing cryptarithms based on small English words (CAT+BAT=HATCAT + BAT = HAT, ONE+ONE=TWOONE + ONE = TWO). Solve each other's puzzles. Discuss the strategies you each used. You will rediscover, on your own, that mathematicians call this kind of search-with-constraints a constraint-satisfaction problem , the same idea that powers Sudoku, scheduling apps, and even AI planning.

Practice quiz

Quick check on this topic.

Quiz
Quick check : Cryptarithms
5 questions · pick the best answer
Q1

In AB+BA=CC\overline{AB} + \overline{BA} = \overline{CC}, C=C = ?

Q2

XXX+XXX=666\overline{XXX} + \overline{XXX} = 666. Find XX.

Q3

In SEND+MORE=MONEYSEND + MORE = MONEY, the value of MM is forced to be

Q4

In the same puzzle, value of OO is

Q5

AA+AA=88\overline{AA} + \overline{AA} = 88. Find AA.