Back to Problems

Problem 16: Power Digit Sum

$2^{15} = 32768$ and the sum of its digits is $3 + 2 + 7 + 6 + 8 = 26$.

What is the sum of the digits of the number $2^{1000}$?

Solution Approach

Exactly as with to Problem 13, this problem was initially intended to be hard due to the fact that when it was written, most languages did not have built-in support for large integers. However, it is once again easily solvable with python.

All we have to do is calculate $2^{1000}$, convert it to a string, and sum up the digits.

In terms of python:


answer = (sum(int(digit) for digit in str(2**1000)))
print(answer)

Explained line by line:

Running the above code leads to an answer of $1366$