Compute n! exactly using BigInt for arbitrarily large results up to 1000!.
The factorial of a non-negative integer n, written n!, is the product of all positive integers from 1 to n. By convention, 0! = 1. Factorials grow extremely fast — 100! has 158 digits. This calculator uses BigInt arithmetic to produce exact results up to 1000! (2568 digits). It never returns Infinity or an approximation.
Factorial definition
n! = n × (n−1) × (n−2) × ... × 2 × 1, with 0! = 1
Stirling approximation
n! ≈ √(2πn) × (n/e)^n
By convention and for consistency with the combinatorial formula: there is exactly one way to arrange zero objects (do nothing). It also ensures n! = n × (n−1)! works for n = 1.
1000! has 2568 digits. Beyond that, the string representation becomes impractically large for display. The computation itself is fast, but rendering thousands of digits offers little practical value.