Free CAT library

Cyclicity, Units Digits & Last Two Digits

Predict the final digits of astronomically large powers using the rules of cyclicity, modular reduction, and binomial expansion patterns.

1. The Story & Mental Model

Imagine a rotating combination lock. You are asked to compute 2992^{99}, a number so large it would wrap around the Earth. But you only care about the last digit. As you calculate powers of 2, the last digit goes: 2, 4, 8, 16 (ends in 6), 32 (ends in 2).

Notice something? It repeats! 2, 4, 8, 6... 2, 4, 8, 6. The last digit is stuck on a wheel with exactly 4 slots.

Instead of calculating 99 times, you just divide the 99 steps by 4. 99÷4=2499 \div 4 = 24 full rotations, with a remainder of 3. That means you land on the 3rd slot of the wheel. The 3rd slot is 8. The unit digit of 2992^{99} is 8. This beautiful looping behavior is called Cyclicity.

2. The CAT Question Blueprint

The CAT rarely asks for the unit digit of a single term anymore. Instead, they will:

  • Ask for the unit digit of a sum or product of massive powers: 345×789+4553^{45} \times 7^{89} + 4^{55}.

  • Escalate to the last two digits of massive powers, especially ones ending in 1, 3, 7, or 9.

  • Combine factorials with cyclicity: "Find the unit digit of 1!+2!+3!+⋯+100!1! + 2! + 3! + \dots + 100!".

3. Core Concepts, Formulae & Derivations

A. Unit Digit Cyclicity Groups

The unit digit of any number NN raised to power PP depends ONLY on the unit digit of NN.

  • Cyclicity of 1: Numbers ending in 0,1,5,60, 1, 5, 6. The unit digit never changes! 51005^{100} ends in 5.

  • Cyclicity of 2: Numbers ending in 4,94, 9.

    • 4odd4^{\text{odd}} ends in 4, 4even4^{\text{even}} ends in 6.

    • 9odd9^{\text{odd}} ends in 9, 9even9^{\text{even}} ends in 1.

  • Cyclicity of 4: Numbers ending in 2,3,7,82, 3, 7, 8.

    • Divide the power PP by 4 and find the remainder RR.

    • If R=1,2,3R=1, 2, 3, the unit digit is the same as (unit)R(unit)^{R}.

    • If R=0R=0, the unit digit is the same as (unit)4(unit)^{4}. (Do NOT use power 0).

B. Finding the Last Two Digits

The last two digits of a number are simply its remainder when divided by 100.

  • Numbers ending in 1: (...a1)n(...a1)^n.

    • The last digit is always 1.

    • The tens digit is the unit digit of (a×n)(a \times n).

    • Example: 314231^{42}. Last digit = 1. Tens digit = 3×2=63 \times 2 = 6. Last two digits = 6161.

  • Numbers ending in 3, 7, 9:

    • Convert them into a power that ends in 1.

    • 34=813^4 = 81 (ends in 1).

    • 74=24017^4 = 2401 (ends in 1).

    • 92=819^2 = 81 (ends in 1).

    • Apply the rule for 1.

  • Numbers ending in even digits:

    • Break into 2n×odd number2^n \times \text{odd number}.

    • Use 210=10242^{10} = 1024. Notice 24odd=2424^{\text{odd}} = 24 and 24even=7624^{\text{even}} = 76.

4. Common Pitfalls & Speed Shortcuts

  • Pitfall: When the power is fully divisible by 4 (remainder 0), students often use x0=1x^0 = 1. This is completely wrong! A remainder of 0 means a full rotation, so you land on the 4th slot. Always use x4x^4.

  • Shortcut: For unit digits of factorial sums, remember that from 5!5! onwards, every factorial ends in 0. So 1!+2!+3!+⋯+100!1! + 2! + 3! + \dots + 100! is just 1+2+6+24+0+0...=331 + 2 + 6 + 24 + 0 + 0... = 33. The unit digit is 3.

Formulas

Cyclicity of 2, 3, 7, 8

R=Power(mod4)R = \text{Power} \pmod 4

If R=0, use power 4. Map to slot R of the sequence.
Last 2 Digits for (...a1)^n

Last 2=(a×unit(n)) concatenated with 1\text{Last 2} = (a \times \text{unit}(n)) \text{ concatenated with } 1

Lightning fast. Example 41^5 -> (4*5=20, take 0) -> 01.

Traps and tips

  • If the remainder is 0 when finding unit digits, use the 4th power, not the 0th power.
  • For last two digits, force the base to end in 1 by raising it to power 2 or 4.
  • Any factorial >= 5! ends in 0. Any factorial >= 10! ends in 00.

Solved examples

The Cyclicity Clash

Find the unit digit of 127134+138135127^{134} + 138^{135}.

Show solution

We only care about the unit digits of the bases: 7 and 8.

Term 1: 71347^{134}

The cyclicity of 7 is 4.

Divide the power 134 by 4. The remainder is 2.

So, 71347^{134} has the same unit digit as 72=497^2 = 49.

The unit digit is 9.

Term 2: 81358^{135}

The cyclicity of 8 is 4.

Divide the power 135 by 4. The remainder is 3.

So, 81358^{135} has the same unit digit as 83=5128^3 = 512.

The unit digit is 2.

Now, add the unit digits: 9+2=119 + 2 = 11.

The final unit digit is 1.

Takeaway: Isolate the unit digits of the base, apply the power mod 4, and then perform the arithmetic operation (add/subtract/multiply) on the resulting single digits.

The Remainder Zero Trap

Find the unit digit of 243100×12280243^{100} \times 122^{80}.

Show solution

Bases are 3 and 2.

Term 1: 31003^{100}

Divide power 100 by 4. Remainder is 0.

TRAP ALERT! Do not use 30=13^0 = 1. A remainder of 0 means 4 full cycles. We use the 4th power.

34=813^4 = 81. Unit digit is 1.

Term 2: 2802^{80}

Divide power 80 by 4. Remainder is 0.

Use the 4th power: 24=162^4 = 16. Unit digit is 6.

Multiply the unit digits: 1×6=61 \times 6 = 6.

The final unit digit is 6.

Takeaway: When the power is a multiple of 4, the cyclicity lands on the 4th slot. Always use the 4th power to find the unit digit.

Last Two Digits: Ending in 1

Find the last two digits of 816781^{67}.

Show solution

This matches the pattern (...a1)n(...a1)^n.

The base is 8181, so a=8a = 8. The power is n=67n = 67.

According to the rule:

  1. The last digit is always 1.

  2. The tens digit is the unit digit of (a×unit digit of n)(a \times \text{unit digit of } n).

    a=8a = 8

    unit digit of nn (67) = 7

    8×7=568 \times 7 = 56.

    The unit digit of 56 is 6. So the tens digit is 6.

Concatenate them: 61.

The last two digits are 61.

Takeaway: For a number ending in 1, the tens digit is (tens of base) (unit of power). It takes 5 seconds.

Forcing the 1

Find the last two digits of 174217^{42}.

Show solution

The base ends in 7. We must transform it into a base ending in 1.

We know 747^4 ends in 1 (specifically, 172=28917^2 = 289, 17417^4 will end in 9×9=19 \times 9 = 1).

Actually, calculating 17417^4 is annoying. Let's use 17217^2 first.

1742=(172)21=(289)2117^{42} = (17^2)^{21} = (289)^{21}.

Now we have a base ending in 9. Let's force it to end in 1 by squaring it.

We need (2892)10×2891(289^2)^{10} \times 289^1.

What are the last two digits of 2892289^2? It's the same as (−11)2=121(-11)^2 = 121. So the last two digits are 21.

Thus, (289)21(289)^{21} has the same last two digits as (21)21(21)^{21}.

Now apply the "ending in 1" rule to 212121^{21}:

  • Last digit is 1.

  • Tens digit is unit digit of (2×1)=2(2 \times 1) = 2.

So 212121^{21} ends in 21.

The last two digits of 174217^{42} are 21.

*(Check via Binomial: 1742=(289)21=(290−1)2117^{42} = (289)^{21} = (290 - 1)^{21}.

Last two terms: ⋯+(211)(290)(−1)20+(−1)21=21(290)−1=6090−1=6089\dots + \binom{21}{1}(290)(-1)^{20} + (-1)^{21} = 21(290) - 1 = 6090 - 1 = 6089. Last two digits: 89. WAIT!)*

CORRECTION: Let me re-evaluate (289)21(289)^{21}.

(289)21=(290−1)21(289)^{21} = (290 - 1)^{21}.

Using binomial expansion for last two digits:

The only terms that don't end in 00 are the last two.

=⋯+(2120)(290)1(−1)20+(2121)(290)0(−1)21= \dots + \binom{21}{20}(290)^1(-1)^{20} + \binom{21}{21}(290)^0(-1)^{21}

=⋯+21×290×1+(−1)= \dots + 21 \times 290 \times 1 + (-1)

=6090−1=6089= 6090 - 1 = 6089.

The last two digits are 89.

Why did (21)21(21)^{21} fail? Because 289≡−11(mod100)289 \equiv -11 \pmod{100}.

(−11)21=−(11)21(-11)^{21} = - (11)^{21}.

Let's apply the rule to 112111^{21}:

Tens digit = 1×1=11 \times 1 = 1. Last digit = 1. So 112111^{21} ends in 11.

−11=100−11=89-11 = 100 - 11 = 89.

Yes! 89 is correct. The forced positive mapping lost the negative sign.

Takeaway: When transforming bases to find the last two digits, using binomial expansion (10k +/- 1)^n is safer and mathematically bulletproof.

Factorial Unit Cascade

Find the unit digit of 1!+2!+3!+⋯+50!1! + 2! + 3! + \dots + 50!.

Show solution

Let's expand the first few factorials:

1!=11! = 1

2!=22! = 2

3!=63! = 6

4!=244! = 24

5!=1205! = 120

6!=7206! = 720

Notice that from 5!5! onwards, every factorial contains both a 2 and a 5 in its expansion. Therefore, it is a multiple of 10, meaning its unit digit is strictly 0.

So the sum of the unit digits is just the sum of the first four:

1+2+6+4+0+0+…1 + 2 + 6 + 4 + 0 + 0 + \dots

=13= 13.

The unit digit of the entire sum is 3.

Takeaway: For sums of factorials, any term from 5! upwards contributes exactly 0 to the unit digit. You only ever need to calculate 1! through 4!.

The $24$ Magic Number

Find the last two digits of 25032^{503}.

Show solution

For even bases, we exploit 210=10242^{10} = 1024.

The last two digits of 2102^{10} are 24.

The magical property of 24 is:

  • 24odd24^{\text{odd}} ends in 24.

  • 24even24^{\text{even}} ends in 76.

Let's break down 25032^{503} into powers of 10:

2503=2500×232^{503} = 2^{500} \times 2^3

=(210)50×8= (2^{10})^{50} \times 8

The last two digits of (210)50(2^{10})^{50} will be the same as the last two digits of (24)50(24)^{50}.

Since 50 is an EVEN power, 245024^{50} ends in 76.

Now, multiply by the remaining 88:

We need the last two digits of 76×876 \times 8.

76×8=60876 \times 8 = 608.

The last two digits are 08.

Takeaway: For powers of 2, factor out 2^10. The last two digits of 2^10 are 24. Then use the rule: 24^odd ends in 24, 24^even ends in 76.

Practice questions

Question 1 · CAT Level

What is the units digit of the sum

S=11!+22!+33!+44!+⋯+100100! ?S = 1^{1!} + 2^{2!} + 3^{3!} + 4^{4!} + \dots + 100^{100!} \text{ ?}

  1. A

    4

  2. B

    5

  3. C

    6

  4. D

    8

Show answer and explanation

Answer: (C) 6

For all integers n≥4n \ge 4, the factorial n!n! contains factor 44, so n!≡0(mod4)n! \equiv 0 \pmod 4.

Because the cyclicity of the units digit of any integer divides 44, nn!n^{n!} has the same units digit as n4n^4 for all n≥4n \ge 4.

In any block of 1010 consecutive integers with exponents that are multiples of 44, the sum of the units digits is:

04+14+24+34+44+54+64+74+84+94≡0+1+6+1+6+5+6+1+6+1=33≡3(mod10)0^4 + 1^4 + 2^4 + 3^4 + 4^4 + 5^4 + 6^4 + 7^4 + 8^4 + 9^4 \equiv 0 + 1 + 6 + 1 + 6 + 5 + 6 + 1 + 6 + 1 = 33 \equiv 3 \pmod{10}.

For n=11n = 11 to 100100, there are 99 complete blocks of 1010, contributing 9×33=297≡7(mod10)9 \times 33 = 297 \equiv 7 \pmod{10}.

For the first 1010 terms (n=1n = 1 to 1010), we evaluate directly:

11+22+36+424+5120+⋯+1010!≡1+4+9+6+5+6+1+6+1+0=39≡9(mod10)1^1 + 2^2 + 3^6 + 4^{24} + 5^{120} + \dots + 10^{10!} \equiv 1 + 4 + 9 + 6 + 5 + 6 + 1 + 6 + 1 + 0 = 39 \equiv 9 \pmod{10}.

Summing both parts gives S≡9+7=16≡6(mod10)S \equiv 9 + 7 = 16 \equiv 6 \pmod{10}.

Question 2 · CAT Level

What are the last two digits of the power tower 73737373^{73^{73}}?

  1. A

    21

  2. B

    29

  3. C

    33

  4. D

    41

Show answer and explanation

Answer: (C) 33

To find 737373(mod100)73^{73^{73}} \pmod{100}, first note gcd⁡(73,100)=1\gcd(73, 100) = 1 and Euler’s totient ϕ(100)=100(1−12)(1−15)=40\phi(100) = 100\left(1 - \frac{1}{2}\right)\left(1 - \frac{1}{5}\right) = 40.

By Euler’s theorem, we need the exponent modulo 4040: E=7373(mod40)E = 73^{73} \pmod{40}.

Since 73≡−7(mod40)73 \equiv -7 \pmod{40}, (−7)2=49≡9(-7)^2 = 49 \equiv 9, and (−7)4≡81≡1(mod40)(-7)^4 \equiv 81 \equiv 1 \pmod{40}, the multiplicative order is 44.

Because 73=4(18)+1≡1(mod4)73 = 4(18) + 1 \equiv 1 \pmod 4, we have 7373≡731≡33(mod40)73^{73} \equiv 73^1 \equiv 33 \pmod{40}.

Now evaluate 7333(mod100)73^{33} \pmod{100}: note 732=5329≡2973^2 = 5329 \equiv 29, and 734≡292=841≡41(mod100)73^4 \equiv 29^2 = 841 \equiv 41 \pmod{100}.

Thus 7333=(734)8×73≡418×73(mod100)73^{33} = (73^4)^8 \times 73 \equiv 41^8 \times 73 \pmod{100}.

For (41)8(41)^8, the units digit is 11 and the tens digit is (4×8)(mod10)=2(4 \times 8) \pmod{10} = 2, giving 2121.

Finally, 21×73=1533≡33(mod100)21 \times 73 = 1533 \equiv 33 \pmod{100}.

Question 3 · CAT Level

What are the last two decimal digits of 12202412^{2024}?

  1. A

    16

  2. B

    36

  3. C

    56

  4. D

    76

Show answer and explanation

Answer: (B) 36

Express the number as 122024=(22×3)2024=24048×3202412^{2024} = (2^2 \times 3)^{2024} = 2^{4048} \times 3^{2024}.

For the power of 22, we use 210=1024≡24(mod100)2^{10} = 1024 \equiv 24 \pmod{100} and 24even≡76(mod100)24^{\text{even}} \equiv 76 \pmod{100}:

24048=(210)404×28≡24404×256≡76×56(mod100)2^{4048} = (2^{10})^{404} \times 2^8 \equiv 24^{404} \times 256 \equiv 76 \times 56 \pmod{100}.

Since 76×2k≡2k(mod100)76 \times 2^k \equiv 2^k \pmod{100} for k≥2k \ge 2, 76×56≡56(mod100)76 \times 56 \equiv 56 \pmod{100}.

For the power of 33, group into powers of 34=813^4 = 81: 32024=(34)506=815063^{2024} = (3^4)^{506} = 81^{506}.

Using the shortcut for numbers ending in 11: the units digit is 11, and the tens digit is (8×6)(mod10)=8(8 \times 6) \pmod{10} = 8, so 81506≡81(mod100)81^{506} \equiv 81 \pmod{100}.

Multiplying the two results: 56×81=4536≡36(mod100)56 \times 81 = 4536 \equiv 36 \pmod{100}.

Question 4 · CAT Level

What are the last two decimal digits of the sum

N=1515+2525+3535+4545+⋯+9595 ?N = 15^{15} + 25^{25} + 35^{35} + 45^{45} + \dots + 95^{95} \text{ ?}

  1. A

    00

  2. B

    25

  3. C

    50

  4. D

    75

Show answer and explanation

Answer: (D) 75

For any integer ending in 55 written as 10a+510a + 5, its power (10a+5)n(10a + 5)^n (with n≥2n \ge 2) satisfies a standard two-digit rule:

1)1) If tens digit aa is even, (10a+5)n≡25(mod100)(10a + 5)^n \equiv 25 \pmod{100} for all integers n≥2n \ge 2.

2)2) If tens digit aa is odd, (10a+5)n≡75(mod100)(10a + 5)^n \equiv 75 \pmod{100} when nn is odd, and 25(mod100)25 \pmod{100} when nn is even.

In our sum, every term has an odd exponent equal to the base itself:

For bases with even tens digits {25,45,65,85}\{25, 45, 65, 85\} (44 terms), each term ends in 2525.

For bases with odd tens digits {15,35,55,75,95}\{15, 35, 55, 75, 95\} (55 terms), each exponent is odd, so each term ends in 7575.

Summing modulo 100100: N≡4(25)+5(75)=100+375=475≡75(mod100)N \equiv 4(25) + 5(75) = 100 + 375 = 475 \equiv 75 \pmod{100}.

Question 5 · CAT Level

What is the units digit of the expression

E=234+345+456+567+678+789+8910+91011 ?E = 2^{3^4} + 3^{4^5} + 4^{5^6} + 5^{6^7} + 6^{7^8} + 7^{8^9} + 8^{9^{10}} + 9^{10^{11}} \text{ ?}

  1. A

    4

  2. B

    6

  3. C

    8

  4. D

    9

Show answer and explanation

Answer: (C) 8

We evaluate the units digit of each term sequentially using modular cyclicity:

2342^{3^4}: 34=81≡1(mod4)  ⟹  21=23^4 = 81 \equiv 1 \pmod 4 \implies 2^1 = 2, and 3453^{4^5}: 45≡0(mod4)  ⟹  34=81→14^5 \equiv 0 \pmod 4 \implies 3^4 = 81 \to 1.

4564^{5^6}: 565^6 is odd, and 4odd4^{\text{odd}} ends in 44.

5675^{6^7} and 6786^{7^8}: powers of 55 end in 55; powers of 66 end in 66.

7897^{8^9}: 89≡0(mod4)  ⟹  74=2401→18^9 \equiv 0 \pmod 4 \implies 7^4 = 2401 \to 1, and 89108^{9^{10}}: 910≡1(mod4)  ⟹  81=89^{10} \equiv 1 \pmod 4 \implies 8^1 = 8.

910119^{10^{11}}: 101110^{11} is even, and 9even9^{\text{even}} ends in 11.

Summing the units digits: 2+1+4+5+6+1+8+1=28≡8(mod10)2 + 1 + 4 + 5 + 6 + 1 + 8 + 1 = 28 \equiv 8 \pmod{10}.

Study this concept with interactive practice in PrepSoc.

Open the concept library