A positive integer has exactly as many 0's at the end as the largest
exponent of 10 which is a factor of the positive integer.
Since 10 = 2*5, we can make the following statement:
Suppose the prime factorization of a positive integer has
n factors of 5 and m factors of 2.
Then if m > n, then the positive integer has exactly n 0's at the end
if m < n, then the positive integer has exactly m 0's at the end.
The prime factorization of 25! contains more factors of 2 than it has
factors of 5, so we only need to know the number of factors of 5.
The prime factorization of
gets 1 factor of 5
from its factors of 5,10,15, and 20, and 2 factors of 5 from its factor
of 25. So the prime factorization of 25! has 6 factors of 5, so it has
6 zeros at the end.
Checking:
25! = 15511210043330985984000000
Edwin