- #1
I_Dont_Know
- 2
- 0
Homework Statement
So here's a little background: This isn't exactly a homework question. I work for a small software company, and everyday I distribute a status update to disclose where we stand with our current software patch development. To keep it interesting, I ask a daily riddle/problem and those who answer correctly receive a prize. Yesterdays question caused a company wide argument as to what the correct probability of the following question is.
Two players each have 1 standard deck of cards (52 cards) PLUS 1 Joker per deck. If each player flips a card over per turn, what are the odds that they will flip the same card value (joker included) before both players have gone through all 53 cards. After nobody answered correctly, I posted the following home-grown, and highly debated solution.
Homework Equations
If we were trying to calculate the probability of each player flipping the same card (suit and value), then the riddle book presents this solution: 1 - ((52/53)^53)
The Attempt at a Solution
1 - ( (13/14)^53) equaling roughly 98%.
Using a Ruby program simulation, I found that 9814 out of 10,000 trials, the players WOULD flip the same card (value only, jokers included) at least once. The simulation accounts for non-replacement, and uniquely generates two unique numbers to produce an index for the two 53 element arrays (containing 52 standard cards, and 1 joker).
My coworkers argue that roughly 98% is completely incorrect, but cannot produce a solution of their own that they are confident in. Can anyone shine some light on this? If you would like me to produce the code for the Ruby program then let me know.
Thanks.
Last edited: