Calculate the highest power of a number in a Factorial?
Table of Contents
In this article, we will learn how to find the highest power of a number in a factorial. We will look at the three different variations of questions based on this concept that you can come across on the GMAT. So, let us get started.
The first variety of question on this concept is –
1. How to find the highest power of a prime number in a factorial.
Let us take an example to understand this. Say, we need to find the highest power of 3 in 20!
In the exam, they can ask you this question in two ways:
Question 1. A
If 20! contains 3^{k}, where k is a positive integer, what is the highest value of k?
Or they can ask the question as show below:
Question 1.B
What is the highest power of 3 in 20!?
The solution is the same for either of the above questions and there are two ways to solve it. We will first solve it using method 1 which is Brute Force method, where we simply count the number of 3s. We’ll then analyse the advantages and disadvantages of this method and then move to a better method (method 2).
Solution
Method 1
 We need to find the highest power of 3 in 20!
Step 1
 Firstly, we will jot down all the multiples of 3 which are less or equal to 20.
 Multiples of 3 which are less than or equal to 20 are 3, 6, 9, 12, 15, and 18.
Step 2
 We will prime factorize the multiples of 3 to get the greatest power of 3 in each of them.
So,

 3 = 3^{1}
 6 = 2^{1}*3^{1}
 9 = 3^{2}
 12 = 2^{2}*3^{1}
 15 = 3^{1}*5^{1}
 18 = 2^{1}*3^{2}
Step 3
 We will add up all the highest powers of 3 obtained from each of its multiple.
 So, the highest power of 3 in 20! = 1 + 1+ 2+ 1+ 1+ 2 = 8
 And thus, k = 8
Disadvantage of Method 1
In this question, it was easy to find the highest power of 3, using method 1, because the factorial value was small. However, this method becomes tedious when the factorial numbers are high. For example, instead of 20! If we had 200! then solving the question using the above method would have taken considerable time.
So, we’ll use another method to solve this type of questions and we would recommend you use the same.
Method 2
 In this method, we take number whose factorial is given. And we keep on dividing it by the powers of the prime number whose highest power we are looking for. On each division, we are simply looking for the quotient.
 The highest power of 3 in 20! = = 6 + 2 = 8
 Here, ( )_Q denotes the quotient of the division operation.
 We know that 20 = 6 * 3 + 2, where 6 is the quotient and 2 is the remainder. So, we’ll just take the quotient 6.
 Similarly, 20 = 2 * 9 + 2. In this case the quotient is 2, so we’ll just take that.
 We know that 20 = 6 * 3 + 2, where 6 is the quotient and 2 is the remainder. So, we’ll just take the quotient 6.
 We’ll continue dividing the factorial number until the quotient, becomes 0.
 Like in the above case the quotient of 20/3^{3} is 0. So, we are not finding it and stopping before that only.
 Here’s another example, let’s say we need to find the highest power of 3 in 60!
 Then, the highest power of 3 in 60! = = 20 + 6 + 2 = 28
 Notice, we have not considered and terms involving other higher powers of 3 in the denominator, because in all those cases the quotient is 0.
 Once you get all the quotients, as you can see, we just need to add up all the quotients and we’ll have the highest power of that prime number in that factorial.
 Then, the highest power of 3 in 60! = = 20 + 6 + 2 = 28
 Here, ( )_Q denotes the quotient of the division operation.
Now, let us look at the second variety of questions.
2. How to find the highest power of a power of prime number in a factorial
In the last section, we learned how to find the highest power of a prime number in a factorial. In this section, we will extend the same concept to find the highest power of a power of prime number( i.e. a number in the form of , where p is a prime number and q is a positive integer greater than 1) in a factorial.
Let us understand with an example.
Question 2
What is the highest power of 8 in 70! ?
Common Mistake:
On seeing this question, a lot of students follow the approach shown below:
 The highest power of 8 in 70! = = 8 + 1 = 9
However, this is INCORRECT, because 8 is not a prime number and we cannot directly divide by a nonprime number to find the highest power of it in a factorial.
The following section explains the correct stepbystep procedure of solving such type of questions.
Solution
Step 1
 Prime factorize the given number to find the prime factor and its highest power.
 Now, prime factorization of 8 =
 Prime factor of 8 = 2
 And the highest power of its prime factor (i.e. 2) in 8 = 3
 Now, prime factorization of 8 =
Step 2
 Find the highest power of the prime factor of the given number in the given factorial
 So, we’ll first find the highest power of 2 in case of 70!
 So, the highest power of 2 in 70! = = 35 +17+8 + 4 +2 +1= 67
Step 3
 Now that we know the highest power of 2, can be written as 2^{67}. But we need the highest power of 8 and we know that we need three twos to make an 8 (since 8 = 2^{3})
 So, we’ll simply divide 67 by 3 in this case and see how many 8’s we can make. In this division, all we need to do is to take the quotient.
 So, the highest power of 8 in 70! =
So, one major learning here is that don’t divide the factorial by a nonprime number. First break the number down into its prime factorized form and then find the highest power of that number. And after that figure out what will be the highest power of that nonprime number.
Till now, we have seen how to find the highest power of a prime number or a power of a prime number, in the next section, we will see how to find the highest power of a number that has two distinct prime number.
Recommended: 3 Important Properties of Prime Numbers
3. How to find the highest power of a number that has two distinct prime numbers
Finding the highest power in this case is only a little bit different from the last section as instead of one prime factor there will be more than one prime factor i.e. the number will be in the form of , where and are prime numbers. So, with the help of an example, let us understand how to solve this type of question.
Question 3
What is the highest power of 10 in 100!?
Solution
Step 1
 Prime factorize the given number.
 So prime factorization of 10 = 2*5
So, now we know that to make one 10 we need one 2 and one 5. So, in our last step, let’s see how many 10s we can make in 100!
Step 2
 The highest power of 2 is 100! = = 50 + 25 + 12 + 6 + 3 +1= 97
 And, the highest power of 5 in 100! = = 20 + 4 = 24
 Hence, the highest power of 2 in 100! is 97 i.e. 100! contains 97 twos or and the highest power of 5 in 100! is 24 i.e. 100! Contains 24 fives or .
 We know that we need one 2 and one 5 to make one 10.
 So, the highest number of 10s that we can make from 97 twos and 24 fives is 24.
 That is, the highest power of 10 in 100! = 24
 If you have noticed the highest power of 10 in 100! is equal to the highest power of 5. This is because the factorial of any number is always going to have more 2s than 5s as 5 > 2 and we need equal number of 2 and 5 to make one 10. So, if you are able to make this inference beforehand, you can save time by finding the highest power of only one number instead of two numbers.
 Therefore, only find the highest power of the greatest prime factor in the factorial.
 So, the highest power of 10 in 100! = the highest power of 5 in 100! = = 20 + 4 = 24
Takeaway
 In questions where you have to find the highest power in a factorial,
 If the number, whose factorial is given, is small, you can count manually to find the highest power.
 If the number, whose factorial is given, is large, then use the division method.
 While using the division method, keep the following points in mind:
 Always prime factorize the number first.
 After that decide, out of the above three, the question falls in which category. And then solve it accordingly to find the highest power of the given number.