Proguessing

Harshil's standard deck of 52 playing cards contains 26 red cards and 26 black cards. Harshil places the randomly shuffled deck on the table, and guesses the colour of the top card before turning it over to reveal its colour. He repeats this with each new top card until he has gone through the whole deck.

If Harshil uses optimal strategy to maximise the chance he guesses correctly, then the expected number of correct guesses he will have once he has gone through the whole deck is equal to a b \frac{a}{b} , where a a and b b are relatively prime, positive integers. What is a + b a+b ?

Bonus: Generalise for B B black cards and R R red cards.


The answer is 3848410234202501.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Mark Hennings
Dec 20, 2018

Let C j C_j be the event that Harshil guesses the j j th card correctly. For any 0 a , b 26 0 \le a,b \le 26 , let X a , b X_{a,b} be the event that the first a + b a+b cards comprise a a Red and b b Black cards. Then P [ X a , b ] = ( 26 a ) ( 26 b ) ( 52 a + b ) 0 a , b 26 P[X_{a,b}] \; = \; \frac{\binom{26}{a}\binom{26}{b}}{\binom{52}{a+b}} \hspace{2cm} 0 \le a,b \le 26 Conditioning on what has happened in the first j 1 j-1 card turns, we see that P [ C j ] = a + b = j 1 P [ C j X a , b ] P [ X a , b ] 1 j 52 P[C_j] \; = \; \sum_{a+b=j-1} P[C_j|X_{a,b}]P[X_{a,b}] \hspace{2cm} 1 \le j \le 52 Harshil's optimal strategy is to guess that the next card to be turned up will be the colour of which fewer has turned up so far (and so is more likely to be the next colour chosen). Thus P [ C a + b + 1 X a , b ] = m a x ( 26 a , 26 b ) 52 a b 0 a , b 26 , a + b < 52 P[C_{a+b+1}|X_{a,b}] \; = \; \frac{\mathrm{max}(26-a,26-b)}{52-a-b} \hspace{2cm} 0 \le a,b \le 26\,,\,a+b < 52 and hence P [ C j ] = a + b = j 1 m a x ( 26 a , 26 b ) 52 a b × ( 26 a ) ( 26 b ) ( 52 a + b ) 1 j 52 P[C_j] \; = \; \sum_{a+b=j-1} \frac{\mathrm{max}(26-a,26-b)}{52-a-b} \times \frac{\binom{26}{a}\binom{26}{b}}{\binom{52}{a+b}} \hspace{2cm} 1 \le j \le 52 Let Z j Z_j be the random variable equal to 1 1 if the j j th card is guessed correctly, and 0 0 otherwise. Then Z = j = 1 52 Z j Z = \sum_{j=1}^{52}Z_j is the total number of correct choices, and E [ Z j ] = P [ Z j = 1 ] = P [ C j ] E[Z_j] = P[Z_j=1] = P[C_j] , and so the expected number of correct guesses made is j = 1 52 P [ C j ] = a + b 51 m a x ( 26 a , 26 b ) 52 a b × ( 26 a ) ( 26 b ) ( 52 a + b ) = 3724430600965475 123979633237026 \sum_{j=1}^{52}P[C_j] \; = \; \sum_{a+b\le51} \frac{\mathrm{max}(26-a,26-b)}{52-a-b} \times \frac{\binom{26}{a}\binom{26}{b}}{\binom{52}{a+b}} \; = \; \frac{3724430600965475}{123979633237026} making the answer 3848410234202501 \boxed{3848410234202501} .

If you assume that R B R\geq B , then you can express

j = 1 R + B P [ C j ] = R + 1 ( R + B B ) k = 0 B 1 ( R + B k ) \sum_{j=1}^{R+B}P[C_j]\; =\; R+\frac{1}{\binom{R+B}{B}}\sum_{k=0}^{B-1}\binom{R+B}{k}

which is the generalisation I was thinking of.

Miles Koumouris - 2 years, 5 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...