exp(p, n!) = \sum_{i=1}^{\infty} \lfloor \frac{n}{p^i}\rfloor

After getting the first formula above, please help me build the more general formula for the exponent of any particular prime in the prime factorization of the product of any set of

consecutive positive integers (which can be expressed as nPr ).

For the purposes of this problem, we introduce the notation

exp(p, nPr)= the exponent of prime p in the PF of nPr

Example: exp(5, 25P6)=3

please help!