Choosing 3 pens from 4 different types of pens is same as x1 + x2 + x3 + x4 = 3 where x1,x2,x3,x4 >= 0.
So at the end we need a total of 3 pens divided into 4 groups. For dividing into 4 groups we need 3 lines.
EX : X | X | X | means (1,1,1,0) ===> Note : We have a total of 3 pens in 4 groups.
X X | X | | means (2,1,0,0)
So dividing 3 pens among 4 groups is nothing but choosing 3 lines among 6 places (3 pens + 3 lines for divding into 4 groups).
So Total number of ways of choosing 3 pens from 4 different types of pens = C(3+3 ,3) = C(6,3) = 20.
We can choose 3 pens of same color in 4 ways (all reds , all greens , all blues , all blacks).
Probability of all 3 pens being same color = number of ways of choosing 3 pens of same color / Total number of ways of choosing 3 pens.
= 4 / 20
= 0.2.
================================
Another way :
choosing 3 pens from 4 different types can be done in 3 ways
- All 3 pens of same color ==> can be done in 4 ways (all reds , all greens , all blues , all blacks)
- Two pens of same color ==> can be done in 4 * 3 ways (4 ways of choosing 2 pens of same color and the other 1 pen can be selected in 3 ways)
- No pens of same color ==> can be done C(4,3) ways.
Probability of all 3 pens being same color = number of ways of choosing 3 pens of same color / Total number of ways of choosing 3 pens
= 4 / [4 + (4*3) + C(4,3)]
= 4 / 20
= 0.2