You are viewing a single comment's thread. Return to all comments →
Python
for _ in range(int(input())): n = int(input()) sn = str(2**n) ans = 0 for d in sn: ans += int(d) print(ans)
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #16: Power digit sum
You are viewing a single comment's thread. Return to all comments →
Python