Factorial Calculator – Solve n!

Enter a number to calculate the factorial n! using the calculator below.

Factorial Number:

n! =
 
Learn how we calculated this below

scroll down


On this page:


How to Calculate a Factorial

In mathematics, the factorial of a number n! is equal to the product of all positive integers up to and including the number. This holds true for all positive whole numbers.

One notable case to be aware of is that the factorial of 0! is equal to 1.

The formula to solve a factorial, including examples to solve the factorial for numbers 1, 2, 3, 4, & 5

Factorial Formulas

The formula to calculate a factorial for a number is:

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

Thus, the factorial n! is equal to n times n minus 1, times n minus 2, continuing until the number 1 is reached.

We can also express the factorial formula a little differently.

n! = 1 × 2 × 3 × … × n

Written a little differently, this states that the factorial n! is equal to 1 times 2 times 3 times each number, repeating until it reaches the number n.

Product Notation

The factorial formula can also be expressed using product notation like this:

Formula to calculate a factorial expressed using product notation

Recurrence Relation

And the formula expressed using the recurrence relation looks like this:

n! = n × (n – 1)!

So the factorial n! is equal to the number n times the factorial of n minus one. This recurses until n is equal to 0.

Factorial Table

The table below shows the factorial n! for the numbers one to one-hundred.

Factorial values for numbers one to one-hundred.
n n!
1 1
2 2
3 6
4 24
5 120
6 720
7 5,040
8 40,320
9 362,880
10 3,628,800
11 39,916,800
12 479,001,600
13 6,227,020,800
14 87,178,291,200
15 1,307,674,368,000
16 20,922,789,888,000
17 355,687,428,096,000
18 6,402,373,705,728,000
19 121,645,100,408,832,000
20 2,432,902,008,176,640,000
21 5.1091E+19
22 1.1240E+21
23 2.5852E+22
24 6.2045E+23
25 1.5511E+25
26 4.0329E+26
27 1.0889E+28
28 3.0489E+29
29 8.8418E+30
30 2.6525E+32
31 8.2228E+33
32 2.6313E+35
33 8.6833E+36
34 2.9523E+38
35 1.0333E+40
36 3.7199E+41
37 1.3764E+43
38 5.2302E+44
39 2.0398E+46
40 8.1592E+47
41 3.3453E+49
42 1.4050E+51
43 6.0415E+52
44 2.6583E+54
45 1.1962E+56
46 5.5026E+57
47 2.5862E+59
48 1.2414E+61
49 6.0828E+62
50 3.0414E+64
51 1.5511E+66
52 8.0658E+67
53 4.2749E+69
54 2.3084E+71
55 1.2696E+73
56 7.1100E+74
57 4.0527E+76
58 2.3506E+78
59 1.3868E+80
60 8.3210E+81
61 5.0758E+83
62 3.1470E+85
63 1.9826E+87
64 1.2689E+89
65 8.2477E+90
66 5.4434E+92
67 3.6471E+94
68 2.4800E+96
69 1.7112E+98
70 1.1979E+100
71 8.5048E+101
72 6.1234E+103
73 4.4701E+105
74 3.3079E+107
75 2.4809E+109
76 1.8855E+111
77 1.4518E+113
78 1.1324E+115
79 8.9462E+116
80 7.1569E+118
81 5.7971E+120
82 4.7536E+122
83 3.9455E+124
84 3.3142E+126
85 2.8171E+128
86 2.4227E+130
87 2.1078E+132
88 1.8548E+134
89 1.6508E+136
90 1.4857E+138
91 1.3520E+140
92 1.2438E+142
93 1.1568E+144
94 1.0874E+146
95 1.0330E+148
96 9.9168E+149
97 9.6193E+151
98 9.4269E+153
99 9.3326E+155
100 9.3326E+157