5 cards from a 52 card deck, what is the probability that the sum of cards is greater than 48

1.4k Views Asked by At

The problem states: $5$ cards are dealt from a standard $52$ card deck. What is the probability that the sum of the values on the five cards is $48$ or more?

It is assumed of course that the value of face cards is $10$ and that of aces $11$. I know I am looking for the ratio between the number of possible outcomes with sum of values at least $48$, and the total number of possible outcomes, but I am having trouble finding the former quantity.

Any help is appreciated, thank you!

2

There are 2 best solutions below

8
On

These are the ways to do it.

A) 4 aces and a card between 4 and 10.

B) 3 aces and two cards whose sum is 15 or higher and whose values are between 5 and 10.

C) 2 aces and three cards whose sum is 26 or higher and whose values are between 6 and 10.

D) 1 ace and 4 cards whose sum is 37 or higher and whose values are between 7 and 10.

E) no aces and 5 cards whose sum is 48 or higher and whose values are between 8 and 10.

So

A) there is one way to have 4 aces. And there are 40 cards between $4$ and $10$. (Ten ranks, 4,5,6,7,8,9,10,J,Q,K and 4 suits. So A) is 40.

B) There are 4 ways to have 3 aces. And the ways to have two cards add to more than 15 are

B1) two 10s. There are $12*11/2$ ways to do this.

B2) a ten and a card between 5 and 9. There are $12$ tens and $5*4$ cards between 5 and 9. So there are $240$ ways to do this.

B3) 2 9s. There are $4*3/2=6$ ways to do this.

B4) A 9 and a card betweem 6 and 8. There are $4*(3*4) = 48$ ways to do this.

B5) two 8s. There are $4*3/2=6$ ways to do this.

B6) an 8 and a 7. There are $4*4=16$ ways to do this.

So B1) = $4*12*11/2$;B2) $4*240$; B3) $4*6$; B4) =$4* 48$ B5) $4*6$; B6) = $4*16$

C) there are $3*4/2$ ways to pick two aces. Two pick three cards that are 26 or higher between $6$ and $10$ are

C1) Three 10s. There are $12*11*10/3!$ ways to do this.

C2) Two 10s. and a card between $6$ and $9$. There are $12*11/2$ times $4*4$ ways to do this.

C3) One 10. and two 9s. There are $12$ times $4*3/2$ ways to do this.

C4) A 10, a 9, and a 7 or an 8. There are $4*4$ times $2*4$ ways to do this.

C5) A 10, and two 8s. There are $4$ times $4*3/2$ ways to do this.

C6) three 9s. There are $4$ ways to do this.

C7) two 9s and an 8. There are $4*3/2$ times $4$ ways to do this.

D) there are $4$ ways to have one ace. The ways to have 4 carsd whose sum is 37 or higher for $7$ through $10$ is:

D1) four tens: $12*11*10*9/4!$ ways to do that.

D2) three tens: and a $7$, $8$ or $9$. $4$ times $3*4$ ways to do that

D3) two 10s, two nines. there are $4*3/2$ times $4*3/2$ ways to do that.

D4) two 10s, a nine and an eight. There are $4*3/2$ times $4*4$ ways to do that.

D5) one 10, 3 nines. There are $4$ times $4*3/2$ ways to do that.

E) the ways to do this are

E1) five 10s. There are $12*11*10*9*8/5!$ ways to do that.

E2) four 10s and an 8 or 9. There are $12*11*10*9/4!$ times $8$ ways to do that.

E3) three 10s and two 9s. There are ${12\choose 3}$ times ${4 \choose 3}$ ways to do that.

Multiply and add them up and divide by ${52 \choose 5}$.

0
On

The number of possible hands, even treating every card as unique, is only $\binom{52}{5} = 2598960$, which is well within brute-force range of a computer.

It's possible to do better, i.e. jointly polynomial in the deck size, hand size, and range of card values, using a dynamic programming algorithm. We can find the distribution of the sum of 5 cards drawn from the deck by iterating over the number of aces $i = 0 \ldots 5$ we could potentially draw:

  • Recursively compute the distribution of the sum of $5 - i$ cards drawn from a deck without aces, memoizing the solution.
  • Add the value of the $i$ aces.

and then binomially weighting the contributions for each $k$. The recursive calls then compute the sum of $0 \ldots 5$ cards drawn from a deck with the 10s/faces also removed, then the 9s also removed, and so forth until only 2s are left. This corresponds to the decomposition of the multivariate hypergeometric distribution as a product of binomials.

I've implemented this in my Icepool Python library. You can run this script online:

from icepool import Deck

deck = Deck([11, 2, 3, 4, 5, 6, 7, 8, 9, 10, 10, 10, 10], times=4)
output(deck.deal(5).sum())

The result is that 55580 out of 2598960 possible hands sum to at least 49, or about 2.14%. Compare 2.60% with replacement (e.g. dice rather than cards).

This approach can be extended to find X-of-a-kind, straights, and more. If you are curious to learn more, you can read my paper on the subject.

@inproceedings{liu2022icepool,
    title={Icepool: Efficient Computation of Dice Pool Probabilities},
    author={Albert Julius Liu},
    booktitle={Eighteenth AAAI Conference on Artificial Intelligence and Interactive Digital Entertainment},
    volume={18},
    number={1},
    pages={258-265},
    year={2022},
    month={Oct.},
    eventdate={2022-10-24/2022-10-28},
    venue={Pomona, California},
    url={https://ojs.aaai.org/index.php/AIIDE/article/view/21971},
    doi={10.1609/aiide.v18i1.21971}
}