Solution to Project Euler Problem 20: Factorial digit sum - n! means n × (n − 1) × ... × 3 × 2 × 1 For example, 10! = 10 × 9 × ... × 3 × 2 × 1 = 3628800, and the sum of the digits in the number 10! is 3 + 6 + 2 + 8 + 8 + 0 + 0 = 27. Find the sum of the digits in the number 100!


Updated: Sept. 21, 2023 — Training Time: 2 minutes
Overseen by: Archangel Macsika
All Training Resources

Scroll for more menu list
Topic: Project Euler Problem 20: Factorial digit sum

Difficulty: Easy.

Objective: n! means n × (n − 1) × ... × 3 × 2 × 1
For example, 10! = 10 × 9 × ... × 3 × 2 × 1 = 3628800,
and the sum of the digits in the number 10! is 3 + 6 + 2 + 8 + 8 + 0 + 0 = 27.
Find the sum of the digits in the number 100!

Input: None.

Expected Output: 648.

Sikademy Solution in Java Programming Language

Sikademy Solution in Python Programming Language

Was this training resource helpful?