Imagine labeling each object so they ARE distinct. Then there are n! permutations. But if the labels are removed from, say, the p which "are of one kind", they are no longer distinct. That is, swapping the positions of two of those things would NOT be a different permutation. Since there are p such things, there are p! ways to swap only those things That is, of the n! ways of ordering those things, there are p! that are only rearranging those identical things- we need to divide by p! to count those as only one. Similarly for the "q" things of another kind and the "r" things of yet another:
[tex]\frac{n!}{p!q!r!}[/tex].