Child Labor #1

Find natural number n n such that 1 ! × 2 ! × 3 ! × 4 ! × . . . × n ! 1! \times 2! \times 3! \times 4! \times . . . \times n! has exactly n n trailing zeros.

Note: This is original problem.


The answer is 13.

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.

1 solution

Jacopo Piccione
Oct 5, 2018

It's called p-adic valuation of a natural number n n , with p p prime, the maximum k k such that p k p^k divides n n : v p ( n ) = m a x { k N : p k n } v_p (n)=max\{k \in \mathbb{N}: \; p^k \mid n\}

Two theorems are useful in this problem: product theorem and Legendre-de Polignac's formula .

  • Product theorem states that v p ( m n ) = v p ( m ) + v p ( n ) v_p(m\cdot n)=v_p(m)+v_p(n)

  • Legendre-de Polignac's formula states that v_p(n!)= \sum_{i=1}^{\infty} \Big{\lfloor} \frac{n}{p^i} \Big{\rfloor}

Their proofs aren't particularly difficult; you can try yourself to find them out if you want.

( 1 ! 2 ! . . . n ! 1!\cdot 2! \cdot ... \cdot n! is called superfactorial and sometimes represented as n $ n\$ , so I will do the same here.)

Now, the number of trailing zeros of n $ n\$ is obviously equal to v 5 ( n $ ) v_5(n\$) . For product theorem and Legendre-de Polignac formula:

v_5(n\$)=v_5(1! \cdot 2! \cdot ... \cdot n!)=v_5(1!)+v_5(2!)+...+v_5(n!)=\displaystyle \sum_{i=1}^{\infty} \Big{\lfloor} \frac{1}{5^i} \Big{\rfloor}+ \displaystyle \sum_{i=1}^{\infty} \Big{\lfloor} \frac{2}{5^i} \Big{\rfloor}+...+\displaystyle \sum_{i=1}^{\infty} \Big{\lfloor} \frac{n}{5^i} \Big{\rfloor}\;\;\;\;\;[A]

We notice also that v 5 ( n ! ) = v 5 ( m ! ) v_5(n!)=v_5(m!) if and only if k N : 5 k n , m < 5 ( k + 1 ) [ B ] \exists k \in \mathbb{N}: 5k \leq n,m < 5(k+1)\;\;\;\;\;[B] .

Now, the problem asks when v 5 ( n $ ) = n v_5(n\$)=n . If n = 1 n=1 we have v 5 ( 1 $ ) = 0 v_5(1\$)=0 , so n > v 5 ( n $ ) n>v_5(n\$) , but, for, let's say, n = 15 n=15 we have n < v 5 ( n $ ) n<v_5(n\$) , since v 5 ( 15 $ ) = 18 v_5(15\$)=18 , so, if n = v 5 ( n $ ) n=v_5(n\$) , it would happen before 15 15 . This calculation are very easy to do, since [ A ] [A] and [ B ] [B] help us a lot. In fact, with very few attempts we find that v 5 ( 13 $ ) = 13 v_5(13\$)=13 so n = 13 n=\boxed{13} .

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...