Factorial Calculator (n!)

Compute the factorial of a whole number (n!), up to 170.

Result

Factorial (n!)

120

How it works

n! = n × (n−1) × … × 2 × 1

The factorial n! multiplies every whole number from n down to 1: 5! = 5×4×3×2×1 = 120. Its natural meaning is counting arrangements — 5! is the number of ways to order 5 distinct objects, which is why factorials sit inside every permutation and combination formula. By convention 0! = 1: there is exactly one way to arrange nothing (the empty arrangement), and the convention keeps formulas like C(n,k) consistent at the edges. Factorials outgrow everything. 10! is 3.6 million; 20! passes 2 quintillion; 170! ≈ 7.3×10³⁰⁶ is the last one a computer's standard floating-point numbers can hold, which is why this calculator stops there. Beyond counting, factorials appear in probability, Taylor series and the mathematics of e.

Advertisement

Frequently asked questions

What is 5 factorial?

5! = 120.

What is 0 factorial?

0! = 1, by definition.

Why does the calculator stop at 170?

Because 171! exceeds the largest number standard double-precision floats can represent (about 1.8×10³⁰⁸). Beyond that, results overflow to infinity; specialized big-number tools are needed.

Advertisement

Related calculators