So many zeroes!

How many trailing zeroes are there at the end of 1000 ! \boldsymbol {1000!} ?


The answer is 249.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

3 solutions

Md Omur Faruque
Aug 2, 2015

If a number has one trailing zero, then it must be a multiple of 10 10 or 5 × 2 5\times2 . So, for a number to have n n trailing zeroes it should have exactly n n pairs of 5 5 & 2 2 in it's factor.

For example, 10 ! = 1 × 2 × 3 × 4 × 5 × 6 × 7 × 8 × 9 × 10 10!=1\times2\times3\times4\times5\times6\times7\times8\times 9\times 10 = 1 × 2 × 3 × 4 × 5 × 6 × 7 × 8 × 9 × 2 × 5 =1\times2\times3\times4\times5\times6\times7\times8\times 9\times2\times 5 = 3628800 =3628800 Which has 2 2 pairs of 5 & 2 5~\& ~2 hence, 2 trailing zeroes.

Now, we have to find how many pairs are there in 1000 ! 1000! 1000 ! = 1 × 2 × 3 × 4..... × 1000 1000!=1\times2\times3\times4.....\times 1000

Let's find the number of fives first. We can find them in every multiple of five. [e. g. 5 , 10 , 15 , . . . 995 , 1000 5, 10, 15, ...995, 1000 ] . So there are 1000 5 = 200 \boldsymbol {\frac {1000}{5}=200} multiples of five in 1000 ! 1000!

But some of them has more than one five in their factor. [ e . g . 25 = 5 × 5 , 125 = 5 × 5 × 5 , 625 = 5 × 5 × 5 × 5 \boldsymbol {[}e.g. 25=5\times 5, 125= 5\times5 \times5, 625=5\times5\times5 \times5 ] \boldsymbol {]}

There are 1000 25 = 40 \boldsymbol {\frac{1000}{25}=40} multiples of 25, 1000 125 = 8 \boldsymbol {\frac{1000}{125} =8} multiples of 125 125 & 1 1 multiple of 625 625 in 1000 ! 1000!

Hence, the total number of 5 5 in the prime factorization of 1000 ! 1000! is, 200 + 40 + 8 + 1 = 249 \boldsymbol {200+40+8+1=\color{#69047E} {\boxed{249}}}

There are 500 500 even numbers between 1 1 to 1000 1000 . So, it's very easy to understand that there will be far more number of 2 2 than 5 5 in the prime factorization of 1000 ! 1000!

So, the number of 5 5 & 2 2 pairs will be 249 \color{#69047E} {\boxed{249}} .

Akshat Sharda
Aug 2, 2015

We can do this directly by a formula,

= [ n k ] + [ n k 2 ] + [ n k 3 ] + [ n k 4 ] + . . . . . . . =[\frac{n}{k}]+[\frac{n}{k^{2}}]+[\frac{n}{k^{3}}]+[\frac{n}{k^{4}}]+.......

We will keep doing this till n > k r n>k^{r} .

Here,

n n = of g ! g!

k k = prime integer

[ . . . ] [...] = highest integral value

From this formula we can calculate the power of a prime number [ k ] [k] which can divide [ g ! ] [g!] .

Hence the one having less power will be the limiting number .

Therefore ,to calculate the number of zeroes ,we'll take k = 5 k=5 and n = 1000 n=1000 .

= [ 1000 5 ] + [ 1000 5 2 ] + [ 1000 5 3 ] + [ 1000 5 4 ] =[\frac{1000}{5}]+[\frac{1000}{5^{2}}]+[\frac{1000}{5^{3}}]+[\frac{1000}{5^{4}}]

= [ 200 ] + [ 40 ] + [ 8 ] + [ 1.6 ] =[200]+[40]+[8]+[1.6]

= 200 + 40 + 8 + 1 = 249 =200+40+8+1=\color{#3D99F6}{\boxed{249}}

汶良 林
Aug 17, 2015

Let's make it easier.

1000 ÷ 5 = 200

200 ÷ 5 = 40

40 ÷ 5 = 8

8 ÷ 5 = 1.6

200 + 40 + 8 + 1 = 249

For example, 12345!, do it this way.

12345 ÷ 5 = 2469

2469 ÷ 5 = 493.8

493 ÷ 5 = 98.6

98 ÷ 5 = 19.6

19 ÷ 5 = 3.8

2469 + 493 + 98 + 19 + 3 = 3082

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...