52-pickup is the practical joke "game" where the mark finds out that the game consists of the proposer spraying all 52 cards of a deck into the air, letting them fall onto the floor, and then the mark has to pick them up.
Suppose all 52 cards are now on the floor, each card randomly and independently face up or down with probability 1/2.
What is the probability that the sum of the face-up cards (counting A, J, Q, K as 1, 11, 12, 13 respectively) is a multiple of 13?
My intuition told me that the answer was 1/13, but I couldn't come up with a concrete reason why. So I wrote the following C# program:
int NUM_TRIALS = 10000000;
int successes = 0;
Random rand = new Random();
for (int i = 0; i < NUM_TRIALS; ++i) // loop once per trial
{
int sum = 0;
for (int j = 1; j <= 13; ++j) // once for each card rank
{
for (int k = 0; k < 4; ++k) // once for each suit
{
if (rand.NextDouble() > .5) // 1/2 probability
{
sum += j;
}
}
}
if (sum % 13 == 0)
{
successes++;
}
}
Console.Out.Write((double)(successes) / NUM_TRIALS);
Output: 0.0769856
1/13 = .0769230
These values are close enough that I'm assuming that 1/13 is the correct answer.
|
Posted by Oren
on 2008-01-16 04:19:51 |