Formula and interpretation
n! = n × (n−1) × … × 1, with 0! = 1.
Factorial is defined here for non-negative whole numbers; values grow extremely quickly.
Worked check
For a small hand check, 5! = 5 × 4 × 3 × 2 × 1 = 120, while 0! = 1 by definition. Factorials grow extremely quickly, so a large output is not automatically an error.
Rule: n! = n × (n−1) × … × 1, with 0! = 1. Factorial is defined here for non-negative whole numbers; values grow extremely quickly. For a final check, estimate the expected size of the answer before copying it, keep units consistent, and round only the displayed result rather than intermediate values. Re-enter one simple case by hand when possible; a result with the wrong sign or order of magnitude usually points to an input or reference-base mistake.