Lots of Twos

2 2 2 2 2 \Large 2^{2^{2^{2^2}}}

Find the last three digits of the number above.


The answer is 736.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Chew-Seong Cheong
Dec 13, 2017

Let N = 2 2 2 2 2 N=2^{2^{2^{2^2}}} . We need to find N m o d 1000 N \bmod 1000 . Since gcd ( 2 , 1000 ) 1 \gcd(2,1000) \ne 1 , we can not use Euler's theorem and we consider the factors of 1000, 2 3 = 8 2^3=8 and 5 3 = 125 5^3=125 using the Chinese remainder theorem as follows:

Consider factor 8: N 0 (mod 8) N \equiv 0 \text{ (mod 8)}

Consider factor 125: Since gcd ( 2 , 125 ) = 1 \gcd(2,125) = 1 , we can apply Euler's theorem as follows:

N 2 2 2 2 2 m o d ϕ ( 125 ) (mod 125) where ϕ ( ) denotes the Euler’s totient function. 2 2 2 2 2 m o d 100 (mod 125) Note that ϕ ( 125 ) = 125 × 4 5 = 100 2 2 16 m o d 100 (mod 125) 2 ( 250 + 6 ) 2 m o d 100 (mod 125) 2 36 (mod 125) ( 250 + 6 ) 4 2 4 (mod 125) 6 4 2 4 (mod 125) 3 4 ( 256 ) (mod 125) 81 6 (mod 125) 111 (mod 125) \begin{aligned} N & \equiv 2^{2^{2^{2^2}} \bmod \color{#3D99F6} \phi(125)} \text{ (mod 125)} & \small \color{#3D99F6} \text{where }\phi (\cdot) \text{ denotes the Euler's totient function.} \\ & \equiv 2^{2^{2^{2^2}} \bmod \color{#3D99F6} 100} \text{ (mod 125)} & \small \color{#3D99F6} \text{Note that }\phi (125) = 125\times \frac 45 = 100 \\ & \equiv 2^{2^{16} \bmod 100} \text{ (mod 125)} \\ & \equiv 2^{(250+6)^2 \bmod 100} \text{ (mod 125)} \\ & \equiv 2^{36} \text{ (mod 125)} \\ & \equiv (250+6)^4 \cdot 2^4 \text{ (mod 125)} \\ & \equiv 6^4 \cdot 2^4 \text{ (mod 125)} \\ & \equiv 3^4 \cdot (256) \text{ (mod 125)} \\ & \equiv 81 \cdot 6 \text{ (mod 125)} \\ & \equiv 111 \text{ (mod 125)} \end{aligned}

N 125 n + 111 where n N 125 n + 111 0 (mod 8) 5 n + 7 0 (mod 8) n 5 \begin{aligned} \implies N & \equiv 125n + 111 & \small \color{#3D99F6} \text{where } n \in \mathbb N \\ \implies 125n + 111 & \equiv 0 \text{ (mod 8)} \\ 5n + 7 & \equiv 0 \text{ (mod 8)} \\ \implies n & \equiv 5 \end{aligned}

N 125 5 + 111 (mod 1000) 736 (mod 1000) \begin{aligned} \implies N & \equiv 125\cdot 5 + 111 \text{ (mod 1000)} \\ & \equiv \boxed{736} \text{ (mod 1000)} \end{aligned}

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...