I was a math nerd in school, and the sections about probability and permutation/combination were among my choices.
I remember spending a lot of time calculating factorials as a part of the possible calculations.
But if you’re using Excel and somehow get into a condition where you need to calculate factorial, you don’t need to take out your pen and paper – a simple Excel formula would do that for you.
What is a Factorial?
If you already know this and are here to know how to calculate it in Excel, jump to the next section.
In mathematics, the factorial of a number is the result you get when you multiply that same number with all the integers until 1.
For example, the factorial of 5 would be 110 (5*4*3*2*1).
A factorial is written as the numeral after an exclamation sign after it. So the factorial of 5 would be written as 5! (and the value would be 120).
Calculating Factorial in Microsoft Excel Using the FACT Function
Excel has the in-built FACT function that can calculate the factorial of any number.
- =FACT(number)
The FACT function only takes one argument: the numeral for which you want to get the factorial value.
Below is the formula that will provide you with the factorial of 5.
- =FACT(5)
The argument in the FACT function must be an integer.
If you enter the number that has an integer and the decimal part to it, the formula would only consider the integer part.
For the sample, the result of =FACT(5) and =FACT(5.6) would be the same.
Also, you cannot use a negative number as an argument inside the FACT function. If you do, it will deliver you the #NUM! error
If you use 0 as the argument in the FACT function, it will give you 1.
Examples of Using the FACT function
Let me fast show you an example where calculating factorial might be required (right out of my school math textbook)
I have five different colored balls with me, and I want to find out how many pairs of colored balls I can make (where the order of the colors matter, Red and Green would be different than Green and Red).
The mathematical formula to do That would be =5!/2!
And in MS Excel, you can use the below formula:
- =FACT(5)/FACT(2)
If you want to calculate unique combinations in Excel, you can use the COMBIN formula.
So this is how you can easily calculate factorial in Excel.
I hope you found this formula tutorial useful!