A fair six-sided die is rolled 10 times, let $X$ denote the total number of $1$'s and let $Y$ denote the total number of primes. Calculate $\Pr(X = 3, Y = 4)$.
Does it mean getting $3$ $1$'s and $4$ prime numbers? The solution is given as: $\displaystyle \frac{10 !}{3! 4! 3!} \left(\frac{1}{6} \right)^3 \left(\frac{1}{2} \right)^4 \left(\frac{2}{6} \right)^3$
Can someone explain it to me in a more detailed way? Thank you.
Yes, that is what it means. (Specifically, exactly 3 "1"'s and exactly 4 prime numbers.)
I am assuming the 10 rolls are independent.
Among the numbers $\{1,2,\dots,6\}$, you have $3$ primes numbers: $\{2,3,5\}$. Therefore, the probability you are seeking is the probability that, out of the 10 rolls, the die hits "1" 3 times (hitting "1" has probability $1/6$), hits a prime number 4 times (hitting a prime number has probability $3/6=1/2$, and hits something else $10-(3+4)=3$ times (probability to hit something else: $(6-1-3)/6=2/6$).
If you just look at the probability that the 3 first rolls are 1, the 4 next are prime numbers, and the last 3 are something else, this gives a probability $$ \left(\frac{1}{6}\right)^3\left(\frac{1}{2}\right)^4\left(\frac{2}{6}\right)^3\tag{1} $$ (can you see why? Here we use the independence.)
However, this is for a fixed order. You need to account for the fact that the 3 "1"'s could be any of the 10 rolls, etc. How many different possibilities are there? Well, you have to partition the $10$ rolls into 3 sets of size 3,4,3, respectively. How many options? This is exactly the multinomial coefficient $$\binom{10}{3,4,3} = \frac{10!}{3!4!3!} \tag{2}$$ that you get.
Since each of these $\binom{10}{3,4,3}$ has probability $\left(\frac{1}{6}\right)^3\left(\frac{1}{2}\right)^4\left(\frac{2}{6}\right)^3$ to occur, overall the probability is $$ \mathbb{P}\{X=3,Y=4\} = \binom{10}{3,4,3}\left(\frac{1}{6}\right)^3\left(\frac{1}{2}\right)^4\left(\frac{2}{6}\right)^3\tag{3} $$ as sought.
Important: why is the number of possibilities $\binom{10}{3,4,3}$ and not, for instance, $10!$? The latter would be the number of permutations of the 10 rolls. That's what you would want if you the particular rolls were distinguishable. But here, it's not the case: you care about the set of indices of the 3 rolls that are prime numbers, but don't want to doublecount different combinations inside this set (e.g., $\{1,4,6\}$ and $\{4,1,6\}$ are the same sets).