[Math] Probability, chose two skittles, out of 2 skittles left from a bag of skittles with 5 colors.

combinatoricsprobabilitystatistics

so me and my friend are studying statistics but we are just stuck on this stupid skittle question we made up ourselves when we tried to guess the colors of the two last skittles so we can see who will eat them.

So out of a bag of skittles we had 2 skittles left, and there are 5 colors.

I guessed red and purple, my friend guesses green and yellow. It turned out that the two skittles were red and purple so I won. After much debate we figured out my hand that there can only be 15 different outcomes such as red,red, green,green, yellow,yellow, purple,purple, orange,orange, red,purple red,yellow and so on…..

What is the actual steps and formula for this? We are stuck at uni studying for so long we can't even solve this simple question ;( Thank you in advanced for the help.

Best Answer

The easiest and most elegant way to find a formula for this is to show you an equivalent problem. This is the case of indistinguishable objects in distinguishable boxes.

Rather than thinking that a Skittle is a particular color, let's have identical beads be placed in one of $5$ boxes, and depending on which box it is in determines its color of the Skittle.

Say we have boxes labeled "red", "green", "yellow", "orange", and "purple". If there were two red Skittles, that's the same as saying both beads were in the red box. If there was one green and one orange Skittle, then one bead was in the green box and the other in the orange box.

So we can count up the ways of putting the beads in boxes and it would be the same thing.

Now, instead of $5$ boxes, let's just split an area into $5$ regions using dividers. Let $|$ be a divider, like so: $$ \square | \square | \square | \square | \square $$

Now let's use stars for our beads, so the two red Skittles example could be represented with: $$ \star \star | | | | $$

Finally, we count up the ways of ordering the stars and stripes, which is the binomial coefficient $\binom{6}{2}$. In general, for $n$ Skittles and $k$ colors, the formula is $\binom{n+k-1}{k}$.

Related Question