<s>[INST] All Unique Three Digit Combinations using four 8s, three 9s, seven 1's and three 5s So basically I have find the unique possible combinations of 3 digit number using four 8s, three 9s, seven 1's and three 5s, e.g.
"888"
"819"
"891"
"855", ..., etc
Because of having same number present multiple times I am not able to determine the answer. Some of the approaches tried were $\frac{17!}{4!3!7!3!}$. All answers are appreciated.
Thanks
 [/INST] These types of questions can be easily solved by exponential generating functions. It will give you power.
It is said that there are four $8's$ , three $9's$ , seven $1's$ , and three $5's$ .In other words , we have $8,8,8,8,9,9,9,1,1,1,1,1,1,1,5,5,5.$
We want to find the number of all possible $3$ digits numbers using these digits without any restriction. So , we should firstly write exponential generating function forms of each digits.
Exponential generating function of $8$ : $$\bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} + \frac{x^4}{4!}\bigg)$$
Exponential generating function of $9$ : $$\bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} \bigg)$$
Exponential generating function of $1$ : $$\bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} + \frac{x^4}{4!} + \frac{x^5}{5!} +\frac{x^6}{6!} +\frac{x^7}{7!}\bigg)$$
Exponential generating function of $5$ : $$\bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} \bigg)$$
Now , to find the number of all possible $3$ digits , we should find the expansion of these exponential generating functions such that $$\bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} + \frac{x^4}{4!}\bigg) \times \bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} \bigg)^2 \times \bigg(1+ \frac{x^1}{1!} + \frac{x^2}{2!} + \frac{x^3}{3!} + \frac{x^4}{4!} + \frac{x^5}{5!} +\frac{x^6}{6!} +\frac{x^7}{7!}\bigg) $$
After that  , we should find the coefficient of $\frac{x^3}{3!}$ or find $x^3$ and multiply it by $3!$. It will give you the result.
Moreover , you can find the number of all possible arrangements of any lenght using this method . For example , if you wnder about lenght $5$ , then  we should find the coefficient of $\frac{x^5}{5!}$ or find $x^5$ and multiply it by $5!$.
</s>