# Math Help - Simple probability question: Hit and miss cards

1. ## Simple probability question: Hit and miss cards

This should be very easy, but I can't get the idea of counting this right:

So I have a stack of 100 cards. 21 of those says "HIT" and 79 says "MISS". What are the odds to take 32 random cards and have 30 of those saying "MISS" and 2 saying "HIT"? The cards are not put back on the stack after pulling one out ie. after that 32nd card there's only 68 left.

I tried to begin this by creating a simple table in "X cards, Y hits" way, but I was only able to get thru the first row (or having a stack of only one card) with knowing that it has to be correct: 79% for "MISS", 21% for "HIT". Then on the second row (or having a stack of only two cards) I'm pretty sure that the "Miss both" is (79/100)*(78/99)=62.24% and "Hit both" is (21/100)*(20/99)=4.24%, but I can't seem to get that one with "Hit one or the other, but not both" correct. I think it should be (79/100)*(21/99)+(21/100)*(78/99)=33.30%, but it seems to make the sum of these three cases to only 99.70% while it should be 100% (you can either hit one, both or neither).

So what's the formula to solve these and what's the actual probability to that "HIT 2 of 32"?

Thanks in advance for anyone trying to help me with this!

2. Originally Posted by jflurrie
This should be very easy, but I can't get the idea of counting this right:

So I have a stack of 100 cards. 21 of those says "HIT" and 79 says "MISS". What are the odds to take 32 random cards and have 30 of those saying "MISS" and 2 saying "HIT"? The cards are not put back on the stack after pulling one out ie. after that 32nd card there's only 68 left.

I tried to begin this by creating a simple table in "X cards, Y hits" way, but I was only able to get thru the first row (or having a stack of only one card) with knowing that it has to be correct: 79% for "MISS", 21% for "HIT". Then on the second row (or having a stack of only two cards) I'm pretty sure that the "Miss both" is (79/100)*(78/99)=62.24% and "Hit both" is (21/100)*(20/99)=4.24%, but I can't seem to get that one with "Hit one or the other, but not both" correct. I think it should be (79/100)*(21/99)+(21/100)*(78/99)=33.30%, but it seems to make the sum of these three cases to only 99.70% while it should be 100% (you can either hit one, both or neither).

So what's the formula to solve these and what's the actual probability to that "HIT 2 of 32"?

Thanks in advance for anyone trying to help me with this!
I marked the the part in red color where things got mixed up a little bit

$\displaystyle $P\left( {MH} \right) + P\left( {HM} \right) = \frac{{79}}{{100}} \cdot \frac{{21}}{{99}} + \frac{{21}}{{100}} \cdot \frac{{79}}{{99}} = 2 \cdot \frac{{79 \cdot 21}}{{100 \cdot 99}} = \frac{{553}}{{1650}}$$

Gives us "miss, then hit" and "hit, then miss" odds in two cards situation.

Now the real deal. Successful combinations:

$\displaystyle $m = \mathop C\nolimits_{79}^{30} \cdot \mathop C\nolimits_{21}^2 = \frac{{79!}}{{30! \cdot (79 - 30)!}} \cdot \frac{{21!}}{{2! \cdot (21 - 2)!}} = {\rm{1164372895197809517019800}}$$

Total combinations:

$\displaystyle $n = \mathop C\nolimits_{100}^{32} = \frac{{100!}}{{32! \cdot (100 - 32)!}} = {\rm{143012501349174257560226775}}$$

Hence odds:

$\displaystyle $P = \frac{m}{n} = \frac{{{\rm{700448925592}}}}{{{\rm{86031677076471} }}} \approx {\rm{0}}{\rm{.8142\% }}$$

3. The best, but very long, way is using a probability tree. At each branch, you have hit or miss, with varying probabilities are you pick more cards and the total probability is given by the product of each card following a particular path.

This would give, in order,

$P(2\ hits,\ 30\ miss) = \left(\dfrac{21}{100}\right)\left(\dfrac{20}{99}\r ight)\left(\dfrac{79}{98}\right)\left(\dfrac{78}{9 7}\right)...\left(\dfrac{50}{69}\right)$

Then,

$P(1\ hit,\ 1\ miss,\ 1\ hit,\ 29\ miss) = \left(\dfrac{21}{100}\right)\left(\dfrac{79}{99}\r ight)\left(\dfrac{20}{98}\right)\left(\dfrac{78}{9 7}\right)...\left(\dfrac{50}{69}\right)$

etc, until:

$P(30\ miss,\ 2\ hits) = \left(\dfrac{21}{100}\right)\left(\dfrac{79}{99}\r ight)\left(\dfrac{20}{98}\right)\left(\dfrac{78}{9 7}\right)...\left(\dfrac{50}{69}\right)$

From this, you can say that you have an idea of how to make a formula to add all those together. The numbers, as you see are the same, only in a different position each time. This will bring us to permutations and combinations!

No. of ways the hits and miss can arrange themselves = $\dfrac{32!}{2!30!}$

$P(any\ 2\ hits\ and\ 30\ miss) = \left(\dfrac{32!}{2!30!}\right)\left(\dfrac{21}{10 0}\right)\left(\dfrac{20}{99}\right)\left(\dfrac{7 9}{98}\right)\left(\dfrac{78}{97}\right)...\left(\ dfrac{50}{69}\right)$

Which is:

$P(any\ 2\ hits\ and\ 30\ miss) = \left(\dfrac{32!}{2!30!}\right)\left(\dfrac{^{21}P _2 \times ^{79}P_{30}}{^{100}P_{32}}\right)$

EDIT: I used 'C' instead of 'P' when I had 21*20, 79*78*77*...*50* *sigh*

This is also be equal to

$P(any\ 2\ hits\ and\ 30\ miss) = \left(\dfrac{^{21}C_2 \times ^{79}C_{30}}{^{100}C_{32}}\right)$

4. Originally Posted by Unknown008
...
$P(any\ 2\ hits\ and\ 30\ miss) = \left(\dfrac{32!}{2!30!}\right)\left(\dfrac{^{21}C _2 \times ^{79}C_{30}}{^{100}C_{32}}\right)$
Which gives an approximate probability of $\displaystyle ${\rm{4}}$$

5. Originally Posted by Pranas
Which gives an approximate probability of $\displaystyle ${\rm{4}}$$
Oops

EDIT: Something seems wrong, I'm looking into it and will correct my above post.

6. There are $\binom{100}{32}$ ways to select the 32 cards, all of which we assume are equally likely.

If there are 30 Misses and 2 Hits, there are $\binom{79}{30}$ ways to select the Misses and $\binom{21}{2}$ ways to select the Hits.

So the probability of 30 Misses and 2 Hits is

$\frac{\binom{79}{30} \binom{21}{2}}{\binom{100}{32}}$.

7. So 0.81% roughly.

Thanks for everyone, I think I also got the idea how to count these now!