**Problem of the Week**

Problem D and Solution

More Power, Mr. Scott!

**Problem**

Mr. Scott likes to pose interesting problems to his Mathematics classes. Today, he started with the expression \(6^{2020}+7^{2020}\). He stated that the expression was not equivalent to \(13^{2020}\) and that he was not interested in the actual sum. His question to his class and to you is, “What are the final two digits of the sum?”

**Solution**

__Solution 1__

Let’s start by examining the last two digits of various powers of 7.

\(7^1=\phantom{16\, 8}{\mbox{\bf 07}}\) | \(7^2=\phantom{117\, 6}{\mbox{\bf 49}}\) | \(7^3=\phantom{823\, }3{\mbox{\bf 43}}\) | \(7^4=\phantom{5\ 76}24{\mbox{\bf 01}}\) |
---|---|---|---|

\(7^5=16\,8{\mbox{\bf 07}}\) | \(7^6=117\,6{\mbox{\bf 49}}\) | \(7^7=823\,5{\mbox{\bf 43}}\) | \(7^8=5\,764\,8{\mbox{\bf 01}}\) |

Notice that the last two digits repeat every four powers of 7. If the pattern continues, then \(7^9\) ends with 07, \(7^{10}\) ends with 49, \(7^{11}\) ends with 43, \(7^{12}\) ends with 01, and so on. We can simply compute these powers of 7 to verify this for these examples, but let’s justify why this pattern continues in general. If a power ends in “07”, then the last 2 digits of the next power are the same as the last 2 digits of the product \(07 \times 7 = 49\). That is, the last 2 digits of the next power are “49”. If a power ends in “49”, then the last 2 digits of the next power are the same as the last two digits of the product \(49\times 7 = 343\). That is, the last two digits of the next power are “43”. If a power ends in “43”, then the last 2 digits of the next power are the same as the last two digits of the product \(43\times 7 = 301\). That is, the last two digits of the next power are “01”. Finally, if a power ends in “01”, then the last 2 digits of the next power are the same as the last two digits of the product \(01\times 7 = 07\). That is, the last two digits of the next power are “07”. Therefore, starting with the first power of 7, every four consecutive powers of 7 will have the last two digits 07, 49, 43, and 01.

We need to determine the number of complete cycles by dividing 2020 by 4. Since \(2020\div 4=505\), there are 505 complete cycles. This means that \(7^{2020}\) is the last power of 7 in the \(505^{\textrm{th}}\) cycle and therefore ends with 01.

Next we will examine the last two digits of various powers of 6.

\(6^1={\mbox{\bf 06}}\) | \(6^2=\phantom{117\,6}{\mbox{\bf 36}}\) | \(6^3=\phantom{1823\ }2{\mbox{\bf 16}}\) | \(6^4=\phantom{00\ 77}12{\mbox{\bf 96}}\) | \(6^5=\phantom{60\ \ 46}77{\mbox{\bf 76}}\) | \(6^6=\phantom{362\ \ 4}46\,6{\mbox{\bf 56}}\) |
---|---|---|---|---|---|

\(6^7=279\,9\mbox{\bf 36}\) | \(6^8=1\,679\,6\mbox{\bf 16}\) | \(6^9=10\,077\,6\mbox{\bf 96}\) | \(6^{10}=60\,466\,1\mbox{\bf 76}\) | \(6^{11}=362\,797\,0\mbox{\bf 56}\) |

Notice that the last two digits repeat every five powers of 6 starting with the \(2^{\textrm{nd}}\) power of 6. This pattern can be justified using an argument similar to the one above for powers of 7. So \(6^{12}\) ends with 36, \(6^{13}\) ends with 16, \(6^{14}\) ends with 96, \(6^{15}\) ends with 76, \(6^{16}\) ends with 56, and so on. Starting with the second power of 6, every five consecutive powers of 6 will have the last two digits 36, 16, 96, 76, and 56.

We need to determine the number of complete cycles in 2020 by first subtracting 1 to allow for 06 at the beginning of the list and then dividing \(2020-1\) or 2019 by 5. Since \(2019\div 5=403\) remainder 4, there are 403 complete cycles and \(\tfrac{4}{5}\) of another cycle. Since \(403 \times 5 = 2015\), \(6^{2015+1}=6^{2016}\) is the last power of 6 in the \(403^{\textrm{rd}}\) cycle and therefore ends with 56.

To go \(\frac{4}{5}\) of the way into the next cycle tells us that the number \(6^{2020}\) ends with the fourth number in the pattern, namely 76. In fact, we know that \(6^{2017}\) ends with 36, \(6^{2018}\) ends with 16, \(6^{2019}\) ends with 96, \(6^{2020}\) ends with 76, and \(6^{2021}\) ends with 56 because they would be the numbers in the \(404^{\textrm{th}}\) complete cycle.

Therefore, \(6^{2020}\) ends with the digits 76.

The final two digits of the sum \(6^{2020}+7^{2020}\) are found by adding the final two digits of \(6^{2020}\) and \(7^{2020}\). Therefore, the final two digits of the sum are \(01+76=77\).

__Solution 2__

From the first solution, we saw that the last two digits of powers of 7 repeat every 4 consecutive powers. We also saw that the last two digits of powers of 6 repeat every 5 consecutive powers after the first power of 6.

Let’s start at the second powers of both 7 and 6. We know that the last two digits of \(7^2\) are \(49\) and the last two digits of \(6^2\) are \(36\). When will this combination of last two digits occur again? The cycle length for powers of 7 is 4 and the cycle length for powers of 6 is 5.

The least common multiple of 4 and 5 is 20. It follows that 20 powers after the second power, the last two digits of the powers of 7 and 6 will end with the same two digits as the second powers of each. That is, the last two digits of \(7^{22}\) and \(7^2\) are the same, namely 49. And, the last two digits of \(6^{22}\) and \(6^2\) are the same, namely 36. The following table illustrates this repetition.

Powers | \(7^2\) | \(7^3\) | \(7^4\) | \(7^5\) | \(7^6\) | \(7^7\) | \(7^8\) | \(7^9\) | \(7^{10}\) | \(7^{11}\) | \(7^{12}\) | \(7^{13}\) | \(7^{14}\) | \(7^{15}\) | \(7^{16}\) | \(7^{17}\) | \(7^{18}\) | \(7^{19}\) | \(7^{20}\) | \(7^{21}\) | \(7^{22}\) |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|

Last 2 digits | 49 |
43 | 01 | 07 | 49 | 43 | 01 | 07 | 49 | 43 | 01 | 07 | 49 | 43 | 01 | 07 | 49 | 43 | 01 | 07 | 49 |

Powers | \(6^2\) | \(6^3\) | \(6^4\) | \(6^5\) | \(6^6\) | \(6^7\) | \(6^8\) | \(6^9\) | \(6^{10}\) | \(6^{11}\) | \(6^{12}\) | \(6^{13}\) | \(6^{14}\) | \(6^{15}\) | \(6^{16}\) | \(6^{17}\) | \(6^{18}\) | \(6^{19}\) | \(6^{20}\) | \(6^{21}\) | \(6^{22}\) |

Last 2 digits | 36 |
16 | 96 | 76 | 56 | 36 | 16 | 96 | 76 | 56 | 36 | 16 | 96 | 76 | 56 | 36 | 16 | 96 | 76 | 56 | 36 |

Since 2000 is a multiple of 20, we then know that the \(2022^{\textrm{nd}}\) power of 7 will end with 49 and that the \(2022^{\textrm{nd}}\) power of 6 will end in 36.

Working backwards through the cycle of the last two digits of powers of 7, it follows that the \(2021^{\textrm{st}}\) power of 7 ends in 07 and that the \(2020^{\textrm{th}}\) power of 7 ends in 01.

Working backwards through the cycle of the last two digits of powers of 6, it follows that the \(2021^{\textrm{st}}\) power of 6 ends in 56 and that the \(2020^{\textrm{th}}\) power of 6 ends in 76.

The final two digits of the sum \(6^{2020}+7^{2020}\) are found by adding the final two digits of \(6^{2020}\) and \(7^{2020}\). Therefore, the final two digits of the sum are \(01+76=77\).