How fast factorials grow
10! = 3,628,800. 20! already has 19 digits, which is past the exact range of a typical calculator. 52!, the number of ways to shuffle a deck of cards, is about 8.07 × 10⁶⁷. This calculator uses exact big-integer arithmetic, so every digit is correct.
Trailing zeros
Each trailing zero comes from a factor of 10 = 2 × 5. Factors of 2 are plentiful, so count the 5s: n ÷ 5 + n ÷ 25 + n ÷ 125 + …, rounding down each time. 100! ends in 20 + 4 = 24 zeros.
Frequently asked questions
Why is 0! equal to 1?
There is exactly one way to arrange zero objects, and defining 0! = 1 keeps formulas like C(n, n) = n! ÷ (n! · 0!) = 1 working.
Can you take the factorial of a negative number or a decimal?
Not with the ordinary definition. The gamma function extends factorials to non-integers (Γ(n + 1) = n!), but it is undefined at negative integers.