Factorial Calculator
Compute n factorial, permutations nPr, combinations nCr, factorial ratios n!/m!, and double factorials n!!. See the full expansion, scientific notation, digit count, and a Stirling approximation for very large values.
🎯Real Factorial Presets
📝Calculation Inputs
Whole number. Exact digits up to 170; above that it overflows to infinity.
Must be 0 to n. Used only in permutation and combination modes.
Must be 0 to n. Used only in factorial ratio mode.
🔢Formula Snapshot
📊Factorial Table 0! to 20!
| n | n! Value | Digits | Scientific |
|---|---|---|---|
| 0 | 1 | 1 | 1.000 × 10^0 |
| 1 | 1 | 1 | 1.000 × 10^0 |
| 2 | 2 | 1 | 2.000 × 10^0 |
| 3 | 6 | 1 | 6.000 × 10^0 |
| 4 | 24 | 2 | 2.400 × 10^1 |
| 5 | 120 | 3 | 1.200 × 10^2 |
| 6 | 720 | 3 | 7.200 × 10^2 |
| 7 | 5,040 | 4 | 5.040 × 10^3 |
| 8 | 40,320 | 5 | 4.032 × 10^4 |
| 9 | 362,880 | 6 | 3.629 × 10^5 |
| 10 | 3,628,800 | 7 | 3.629 × 10^6 |
| 11 | 39,916,800 | 8 | 3.992 × 10^7 |
| 12 | 479,001,600 | 9 | 4.790 × 10^8 |
| 13 | 6,227,020,800 | 10 | 6.227 × 10^9 |
| 14 | 87,178,291,200 | 11 | 8.718 × 10^10 |
| 15 | 1,307,674,368,000 | 13 | 1.308 × 10^12 |
| 16 | 20,922,789,888,000 | 14 | 2.092 × 10^13 |
| 17 | 355,687,428,096,000 | 15 | 3.557 × 10^14 |
| 18 | 6,402,373,705,728,000 | 16 | 6.402 × 10^15 |
| 19 | 121,645,100,408,832,000 | 18 | 1.216 × 10^17 |
| 20 | 2,432,902,008,176,640,000 | 19 | 2.433 × 10^18 |
🗂Permutations vs Combinations Reference
| Concept | Formula | Order Matters | Example | Value |
|---|---|---|---|---|
| Factorial | n! = 1×2×...×n | Arrangement | 5! | 120 |
| Permutation | nPr = n! / (n-r)! | Yes | 10P3 | 720 |
| Combination | nCr = n! / (r!(n-r)!) | No | 10C3 | 120 |
| Ratio | n!/m! = (m+1)...n | Cancels | 8!/3! | 6,720 |
| Double | n!! = n(n-2)(n-4)... | Same parity | 9!! | 945 |
| Full deck | 52C5 | No | Poker hands | 2,598,960 |
| Lottery | 49C6 | No | 6 of 49 | 13,983,816 |
📈Growth and Stirling Comparison
| n | Exact n! | Digits | Stirling Est. | Rel. Error |
|---|---|---|---|---|
| 1 | 1 | 1 | 0.9221 | 7.79% |
| 2 | 2 | 1 | 1.919 | 4.05% |
| 5 | 120 | 3 | 118.02 | 1.65% |
| 10 | 3,628,800 | 7 | 3,598,696 | 0.83% |
| 15 | 1.308 × 10^12 | 13 | 1.300 × 10^12 | 0.55% |
| 20 | 2.433 × 10^18 | 19 | 2.423 × 10^18 | 0.42% |
| 50 | 3.041 × 10^64 | 65 | 3.036 × 10^64 | 0.17% |
| 100 | 9.333 × 10^157 | 158 | 9.325 × 10^157 | 0.08% |
| 170 | 7.257 × 10^306 | 307 | 7.254 × 10^306 | 0.05% |
⚙Full Formula Breakdown
📋Common Use Cases
| Question | Mode | Setup | Answer |
|---|---|---|---|
| Ways to order 5 books | n! | n = 5 | 120 |
| Top-3 finish, 10 runners | nPr | 10P3 | 720 |
| Pick 3 friends of 10 | nCr | 10C3 | 120 |
| Five-card poker hands | nCr | 52C5 | 2,598,960 |
| 6-of-49 lottery tickets | nCr | 49C6 | 13,983,816 |
| Shrink 8! by 3! | Ratio | 8!/3! | 6,720 |
💡Practical Factorial Tips
Factorial is an easy concept except when you need to figure out factorial beyond a small handful of things. It’s simply multiplying all integers starting with 1 through to whatever number you want. But it grow far too quickly for us to easily understand. That’s what calculators are for. Calculators can does the kind of maths that no human brain can cope with. Or, at least, not in Excel beyond a spreadsheet cell or two.
The numbers get too big: they become difficult to understand unless you use scientific notation. To know what you’re talking about when you count it can help. Are you arranging books in a row on a bookshelf? You have an arrangement; that’s a permutation problem. Are you picking a team of friends to go on a trip? The positions doesn’t matter; it’s just who is on the team. So, that’s a combination problem.
What Factorials Are Used For
And this is where many people mess up because the math process for each is identical: they both use multiplication. But, one asks about possible choices. The other ask about how many ways there are to make those choices. One is counting selections. The other arrangements. Once you know which one you’re trying to solve it becomes easier to work through.
When you stop to think about it, zero factorial being equal to one is pretty cool math. It goes against intuition since how could multiplying something with nothing be anything other then zero? But again, the math are defined that way to maintain consistency across all these equations. Without the exception, there are branches of combinatorics and probability where things fall apart. It is a little definition but it is an important one for maintaining the structure of the math.
The calculator handles the edge case for you so you can worry about data you enter instead of an old math rule. As numbers increase, they becomes more difficult to manage. Once you go past ten factorial (seven digits) or twenty factorial (nineteen digits), the digits starts to add up faster than you can count them. For larger numbers, we use scientific notation. Which is exactly what the calculator does for you once the number starts becoming unmanageable: it converts it to a mantissa and power of ten representation. That way, there’s no chance of the number overflowing into nothingness, an error encountered in most computing systems where numbers just… dissapears. It will also tell you how many digit are present so you know roughly how big the number is without having to count each zero.
For very large input numbers, there’s also an approximation method with Stirling’s formula. This isn’t exact, it’s close enough for larger numbers. The farther out you go, the smaller the relative error become. This makes it valuable in theory, when the order of magnitude might matter a lot more than precision. Here you can see just how predictable mathematical chaos can be by comparing this estimate against the exact number. Even though things gets wild with growth, there remains an underlying structure that you can model.
Once you begin to look around, the practical applications are many. Factorials allow for lottery odds (each ticket has the same probability of winning). They’re part of computer science analysis of algorithms. This includes sorting which is a common problem that requires comparing items. And they are used by game developers to weight random events or card values. The progression can be seen easily on reference tables showing just how rapidly manageable problems turns into computationally intensive ones.
The second thing to note about the double factorial option is that it leaves out every other number in the chain. Used in certain geometry and physics problems, this creates its own growth pattern different than regular factorials. While still very much a niche option, it’s another example of how useful the tool can be when it comes to complex problem-solving tasks.
Whether you’re doing your homework or trying to calculate the chances of winning the lottery, having all of these variations available in one location help simplify the task at hand. Ultimately, it’s less about calculating the number and more about understanding what that number means for your particular situation. It’s easy to see how a simple rule can produce immense complexity: factorials. Hundreds of digit numbers created through nothing more than a few multiplications; the stuff passwords are made of; the stuff genetics is made of; the stuff your phone bill is made of.
You don’t have to learn them off by heart. No one asks you to work out the formula on paper, let alone perform the multiplications. The true talent here is knowing which situations call for an exact answer and which are happy to settle for an approximation. It’s about understanding the concept behind selection and order. The rest is left to the maths.

