Summer is Coming! Join the Game of Timers Competition to Win Epic Prizes. Registration is Open. Game starts Mon July 1st.

 It is currently 16 Jul 2019, 11:55

### GMAT Club Daily Prep

#### Thank you for using the timer - this advanced tool can estimate your performance and suggest more practice questions. We have subscribed you to Daily Prep Questions via email.

Customized
for You

we will pick new questions that match your level based on your Timer History

Track

every week, we’ll send you an estimated GMAT score based on your performance

Practice
Pays

we will pick new questions that match your level based on your Timer History

# Question on terminating zero's?

Author Message
TAGS:

### Hide Tags

Director
Joined: 29 Nov 2012
Posts: 732

### Show Tags

16 Jun 2013, 02:21
5
11
If we were given a question to find the number of zero's in the product of the first 100 integers then can we use the following

we know that to find the zero's we need 5 and 2 so we can focus on the 5's

$$100/5 + 100/ 5^2 + 100/5^3 + 100/5^4$$....

we get 20 + 4 + 0 + 0 ( I know you can stop at 5^3 but just wrote the extra step for a general case)

so there will be 24 zeros? Is this approach correct and can I use it for all such questions
VP
Status: Far, far away!
Joined: 02 Sep 2012
Posts: 1044
Location: Italy
Concentration: Finance, Entrepreneurship
GPA: 3.8
Re: Question on terminating zero's?  [#permalink]

### Show Tags

16 Jun 2013, 02:28
1
Yes, that's correct.

Whenever you are asked for the trailing zeros of a given integer, just find the total number of 2-5 pairs.

So total trailing zeros of 43! is 9 for example:
40*...*35*...*30*..*25*...*20*...*15*..*10*..*5 they have 9 fives (25 has 2) so there are 9 zeros.

Most of the times it's all about counting the 5s because the number of 2s will be greater
_________________
It is beyond a doubt that all our knowledge that begins with experience.
Kant , Critique of Pure Reason

Tips and tricks: Inequalities , Mixture | Review: MGMAT workshop
Strategy: SmartGMAT v1.0 | Questions: Verbal challenge SC I-II- CR New SC set out !! , My Quant

Rules for Posting in the Verbal Forum - Rules for Posting in the Quant Forum[/size][/color][/b]
Math Expert
Joined: 02 Sep 2009
Posts: 56244
Re: Question on terminating zero's?  [#permalink]

### Show Tags

16 Jun 2013, 03:10
4
7
fozzzy wrote:
If we were given a question to find the number of zero's in the product of the first 100 integers then can we use the following

we know that to find the zero's we need 5 and 2 so we can focus on the 5's

$$100/5 + 100/ 5^2 + 100/5^3 + 100/5^4$$....

we get 20 + 4 + 0 + 0 ( I know you can stop at 5^3 but just wrote the extra step for a general case)

so there will be 24 zeros? Is this approach correct and can I use it for all such questions

Trailing zeros:
Trailing zeros are a sequence of 0's in the decimal representation (or more generally, in any positional representation) of a number, after which no other digits follow.

125000 has 3 trailing zeros;

The number of trailing zeros in the decimal representation of n!, the factorial of a non-negative integer n, can be determined with this formula:

$$\frac{n}{5}+\frac{n}{5^2}+\frac{n}{5^3}+...+\frac{n}{5^k}$$, where k must be chosen such that 5^(k+1)>n

It's more simple if you look at an example:

How many zeros are in the end (after which no other digits follow) of 32!?
$$\frac{32}{5}+\frac{32}{5^2}=6+1=7$$ (denominator must be less than 32, $$5^2=25$$ is less)

So there are 7 zeros in the end of 32!

The formula actually counts the number of factors 5 in n!, but since there are at least as many factors 2, this is equivalent to the number of factors 10, each of which gives one more trailing zero.

BACK TO THE ORIGINAL QUESTION:

According to above 100! has $$\frac{100}{5}+\frac{100}{25}=20+4=24$$ trailing zeros.

For more on trailing zeros check: everything-about-factorials-on-the-gmat-85592-40.html

Similar questions to practice:
if-73-has-16-zeroes-at-the-end-how-many-zeroes-will-147353.html
if-60-is-written-out-as-an-integer-with-how-many-101752.html
how-many-zeros-does-100-end-with-100599.html
find-the-number-of-trailing-zeros-in-the-expansion-of-108249.html
find-the-number-of-trailing-zeros-in-the-product-of-108248.html
if-n-is-the-product-of-all-multiples-of-3-between-1-and-101187.html
if-m-is-the-product-of-all-integers-from-1-to-40-inclusive-108971.html
if-p-is-a-natural-number-and-p-ends-with-y-trailing-zeros-108251.html
if-10-2-5-2-is-divisible-by-10-n-what-is-the-greatest-106060.html
p-and-q-are-integers-if-p-is-divisible-by-10-q-and-cannot-109038.html
if-n-is-the-product-of-integers-from-1-to-20-inclusive-106289.html
what-is-the-greatest-value-of-m-such-that-4-m-is-a-factor-of-105746.html
if-d-is-a-positive-integer-and-f-is-the-product-of-the-first-126692.html
if-10-2-5-2-is-divisible-by-10-n-what-is-the-greatest-106060.html

Hope it helps.
_________________
Intern
Joined: 19 Jun 2016
Posts: 1
Re: Question on terminating zero's?  [#permalink]

### Show Tags

09 Sep 2016, 18:12
Zarrolou wrote:
Yes, that's correct.

Whenever you are asked for the trailing zeros of a given integer, just find the total number of 2-5 pairs.

So total trailing zeros of 43! is 9 for example:
40*...*35*...*30*..*25*...*20*...*15*..*10*..*5 they have 9 fives (25 has 2) so there are 9 zeros.

Most of the times it's all about counting the 5s because the number of 2s will be greater

Hello! can you explain how you get the 9 zeros out of 43!?
the part i´m confused in is when you say (25 has 2)
i get it that you have 8 pairs of 5:
40...35..30...25...20...15..10...5 but this gives me just 8 =S

thank you!!
Manager
Joined: 28 Jun 2016
Posts: 216
Concentration: Operations, Entrepreneurship
Re: Question on terminating zero's?  [#permalink]

### Show Tags

09 Sep 2016, 22:52
Valdescat wrote:
Zarrolou wrote:
Yes, that's correct.

Whenever you are asked for the trailing zeros of a given integer, just find the total number of 2-5 pairs.

So total trailing zeros of 43! is 9 for example:
40*...*35*...*30*..*25*...*20*...*15*..*10*..*5 they have 9 fives (25 has 2) so there are 9 zeros.

Most of the times it's all about counting the 5s because the number of 2s will be greater

Hello! can you explain how you get the 9 zeros out of 43!?
the part i´m confused in is when you say (25 has 2)
i get it that you have 8 pairs of 5:
40...35..30...25...20...15..10...5 but this gives me just 8 =S

thank you!!

25 has two 5's. and other numbers have one five each,

So 2+7=9
Manhattan Prep Instructor
Joined: 04 Dec 2015
Posts: 756
GMAT 1: 790 Q51 V49
GRE 1: Q170 V170
Re: Question on terminating zero's?  [#permalink]

### Show Tags

12 Sep 2016, 10:39
1
Valdescat wrote:
Zarrolou wrote:
Yes, that's correct.

Whenever you are asked for the trailing zeros of a given integer, just find the total number of 2-5 pairs.

So total trailing zeros of 43! is 9 for example:
40*...*35*...*30*..*25*...*20*...*15*..*10*..*5 they have 9 fives (25 has 2) so there are 9 zeros.

Most of the times it's all about counting the 5s because the number of 2s will be greater

Hello! can you explain how you get the 9 zeros out of 43!?
the part i´m confused in is when you say (25 has 2)
i get it that you have 8 pairs of 5:
40...35..30...25...20...15..10...5 but this gives me just 8 =S

thank you!!

Breaking it down a little further: let's start with a simpler example. How many trailing zeroes are there in 25*24*23*22*21*20?

The number of zeroes will be the same as the number of 10s in that product. The only way to get a trailing zero is to multiply something by 10, after all.

To figure out how many 10s are in the product, you'd need to rearrange it slightly. A 10 is composed of a 5 and a 2. So, you'll want to check how many 5s and 2s there are in the product. Rewrite the product to reflect this:

25*24*23*22*21*20
(5*5)*(2*2*2*3)*(23)*(2*11)*(3*7)*(2*2*5)

Notice that there are way more 2s than there are 5s. We'll run out of 5s before we run out of 2s. So, we really only need to count the 5s.

There are three of them in total:

(5*5)*(2*2*2*3)*(23)*(2*11)*(3*7)*(2*2*5)

You can stop there, and just say 'okay, so there are 3 trailing zeroes'. But here's the deeper explanation of why that's the case. You could put the product in a slightly different order: pair each of those 5s with a 2. That's allowed, because when you're multiplying, it doesn't matter what order you multiply things in.

(5*5)*(2*2*2*3)*(23)*(2*11)*(3*7)*(2*2*5)
(5*5)*(2*2*2*3)*(23)*(2*11)*(3*7)*(2*2*5)
5*2 * 5*2 * 5*2 * 3 * 23 * 2 * 11 * 3 * 7 * 2 * 2
10 * 10 * 10 * 3 * 23 * 2 * 11 * 3 * 7 * 2 * 2

There are your three 10s, so you've definitely got three trailing zeroes. To check the math, you can plug that multiplication into a calculator and confirm that (5*5)*(2*2*2*3)*(23)*(2*11)*(3*7)*(2*2*5) comes out the same as 10 * 10 * 10 * 3 * 23 * 2 * 11 * 3 * 7 * 2 * 2.

There's no need to do all of this when you actually do a terminating zeroes problem on test day, though. The 'shortcut' is just to count the powers of 5. But notice how when we multiplied everything out, 25 contributed two fives? That means you need to count 25 twice. Anything that's a product of multiple fives (for example, 250 = 5*5*5*2), you'll need to count all of them separately.
_________________

Chelsey Cooley | Manhattan Prep | Seattle and Online

My latest GMAT blog posts | Suggestions for blog articles are always welcome!
Non-Human User
Joined: 09 Sep 2013
Posts: 11658
Re: Question on terminating zero's?  [#permalink]

### Show Tags

24 Mar 2019, 05:28
Hello from the GMAT Club BumpBot!

Thanks to another GMAT Club member, I have just discovered this valuable topic, yet it had no discussion for over a year. I am now bumping it up - doing my job. I think you may find it valuable (esp those replies with Kudos).

Want to see all other topics I dig out? Follow me (click follow button on profile). You will receive a summary of all topics I bump in your profile area as well as via email.
_________________
Re: Question on terminating zero's?   [#permalink] 24 Mar 2019, 05:28
Display posts from previous: Sort by