You are viewing a single comment's thread. Return to all comments →
100% python
import math n = int(input()) ans = 0 for num in range(10, n): s = [math.factorial(int(i)) for i in " ".join(str(num)).split()] if sum(s) % num == 0: ans += num print(ans)
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #34: Digit factorials
You are viewing a single comment's thread. Return to all comments →
100% python