Find the prime factor decomposition of $100!$ and determine how many zeros terminates the representation of that number.

Actually, I know a way to solve this, but even if it is very large and cumbersome, and would like to know if you have an easier way, or if I am applying wrong. Setting by $\left[\frac{b}a \right]$ the quotient of $b$ with $a$, we have too $E_p(m)$ the largest exponent power $p$ dividing $m$, and found the demonstration of a theorem that says (that in my text says it was discovered that Lagendre) $$E_p(n!)=\left[\frac{n}p \right]+\left[\frac{n}{p^2} \right]+\left[\frac{n}{p^3} \right]+\;...$$always remembering that there will be a number $s$ such that $p^s\geq n!$ which tells us that $$\left[\frac{n!}{p^s} \right]=0$$ thus making the sum of a finite $E_p(n!)$. So that I can address the first question I asked, really have to get all the cousins $(p_1,p_2,...,p_k)$ and make all $$E_{p_1},\;E_{p_2},\;E_{p_3},\;...,\;E_{p_k}$$ with $p$ and cousin $1<p<100$. And to find the zeros have to see how we both exponents in numbers 5 and 2.

Example $$10!=2^83^45^27\\p<10\\E_2(10!)=5+2+1=8\\E_3(10!)=3+1=4\\E_5(10!)=2\\E_7(10!)=1\\$$


marked as duplicate by davidlowryduda Oct 19 '17 at 11:51

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 2
    $\begingroup$ Yes, that's the way. Note that you can easily show that $n!$ always has at least as many factors $2$ as factors $5$, so looking at the power of $5$ is enough. $\endgroup$ – Daniel Fischer Nov 19 '13 at 22:47
  • $\begingroup$ @DanielFischer So that I can find the factorization into prime numbers 100! I really have to do all of this giant? $\endgroup$ – marcelolpjunior Nov 19 '13 at 22:51
  • $\begingroup$ @marcelolpjunior For a full factorisation you'd still need to go the cumbersome way. Only shortcuts if you only care for certain powers (i.e. $5$) $\endgroup$ – AlexR Nov 19 '13 at 22:53
  • 1
    $\begingroup$ Well, not quite. You know that all primes $53,59,\dotsc,89,97$ appear with exponent $1$. $37,41,43,47$ with exponent $2$. $29,31$ with exponent $3$, etc. Only for the primes below $\sqrt{100}$ there's a nontrivial amount of computation to do. $\endgroup$ – Daniel Fischer Nov 19 '13 at 22:54
  • $\begingroup$ Check your answer here: wolframalpha.com/input/?i=factor+100%21. $\endgroup$ – lhf Nov 19 '13 at 23:16

It's possible to demonstrate that if N is a multiple of 100, N! ends with (N/4)-1 zeroes.

  • $\begingroup$ And how would this statement made​​? $\endgroup$ – marcelolpjunior Nov 20 '13 at 9:30
  • 3
    $\begingroup$ It's not true. Consider $N = 600$. $$\left\lfloor\frac{600}{5} \right\rfloor + \left\lfloor \frac{600}{25}\right\rfloor + \left\lfloor \frac{600}{125}\right\rfloor = 120 + 24 + 4 = 148 = \frac{600}{4} - 2.$$ By @Daniel Fischer... $\endgroup$ – marcelolpjunior Nov 20 '13 at 15:29

Not the answer you're looking for? Browse other questions tagged or ask your own question.