View Full Version : The 821 Game
Monte314
06-06-2008, 05:56 AM
I was strolling down the fairway at the carnival, and was intrigued to see a gaming booth set up with two computers on a table; the game operator was standing beside them. This was something completely new among all the standard dart-throwing-ring-tossing gimmicks… I had to check it out.
“So”, I asked the operator, ”whudya’ got here?”
He began his banter. “You, sir, are the first gamer of the day, so I have a special contest for you.” He extended a hand toward the computers.
“Here we have two identical computers. They are not connected in any way. When you press the space bar on one of these machines, it displays on its screen a randomly selected number between 0 and 1. To play the game, you press the spacebar on both machines; if the sum of the two random numbers displayed is one-half or less, you win. Otherwise, the house wins. Would you like to try your luck?”
I hesitated. “What does it cost to play, and what’s the prize?”
The operator grinned. “Believe it or not, sir, it costs only $1 to play, but the house pays $8 if you win.”
I was stunned. “You’ll pay me eight times my wager if the sum is less than or equal to a half? Really?”
The operator smiled. “Yes, sir!”
Assuming the game is honest and I play, say, a MILLION times, what should I expect to happen?
Interesting question, I think I got it. I put it in the interests section of my profile.
Monte314
06-06-2008, 07:37 PM
I have worked up a nice graphic that shows how to solve problems like this. I'll find a way to post it later.
This is one of those problems that, if you aren't sure how to attack it analytically, you can write a simple simulation. I did so for this problem (it's about 40 lines of code, with graphics) and ran 1 BILLION games this afternoon. I'll make those results available, too. (Fortunately, the simulation agrees with the analytic solution to 5 decimal places!)
44sunsets
06-06-2008, 07:55 PM
Interesting game. Does it have an official name?
Seems to me that it would be quite difficult to win, although it sounds easy to win if you're not paying close attention when the setup is described to you. I'm terrible at maths, but the odds would be quite slim I would guess?
Monte314
06-06-2008, 08:51 PM
I made it up. the payout is $8 for a $1 cost to play, so I'm calling in "821".
You are on the right track wth your intuitive assessment.
To be less than 0.5 the first must less than 0.25 and the second too. 1/4 * 1/4 = 1/16 so he would lose half his money.
To be less than 0.5 the first must less than 0.25 and the second too. 1/4 * 1/4 = 1/16 so he would lose half his money.
Yeah, that's what I got.
Not as challenging as the first, still super cool. :thumbsup:
Monte314
06-07-2008, 08:44 AM
I posted a link to a helpful picture I generated on Member pictures vol. 3, (#623).
You have to be careful here, since it is *not* necessary that both numbers be less than 1/4. For example, one of the numbers could be 0.49, and the other 0.01 (so the probability of getting a sum <=1/2 is bigger than 1/16). But you are on the right track here.
This problem sounds kind of theoretical, but it turns out that lots of useful problems can be solved using the trick shown in the diagram I posted. (The graphics and numeric information in the diagram were generated by the simulation I wrote to create an empirical estimate of the solution. If anyone wants the code, send me a PM and I'll email you source and executable.)
I'll put up some other examples of this type of problem later this week.
I'm also grooming some puzzles I've used in my classes involving infinity... I'll put some of these up later this month if people are interested.
vkut79
06-07-2008, 09:32 AM
To be less than 0.5 the first must less than 0.25 and the second too. 1/4 * 1/4 = 1/16 so he would lose half his money.
Nope, for example the first could be 0.4 and the second could be 0.05. Still below 0.5 total.
vkut79 added to this post, 2 minutes and 20 seconds later...
I'll put up some other examples of this type of problem later this week.
I'm also grooming some puzzles I've used in my classes involving infinity... I'll put some of these up later this month if people are interested.
Cool, thanks. Are you a professor/teacher?
Monte314
06-07-2008, 10:56 AM
Yes, I have been teaching for over 30 years (mostly university students... I'm supervising 4 Master's Theses right now).
Along the way, I have gathered up loads of interesting problems and puzzles (I'm a mathematician). I think these are worth sharing when they illustrate some problem solving method, or are particularly entertaining.
INTJ's seem to enjoy thinking about things like this. My intention is to occassionaly post some of these, as long as there is interest.
Nope, for example the first could be 0.4 and the second could be 0.05. Still below 0.5 total.
Do this then. Think of the 2 computers picks of random numbers as the axis of a graph. Clearly one point is (0.5,0), another is (0,0.5), so is (0.25, 0.25). What you have is a the area of the triangle in the bottom left covering all possible combinations. You will clearly see this is 1/16th of the square bounded by (1,0), (0,1).
Edit: just looked at your picture. That is how I see it too.
Monte314
06-07-2008, 11:40 AM
Bingo! (but it's 1/8, not 1/16).
Monte314
06-07-2008, 05:31 PM
Now to complete the solution to the riddle.
The most important aspect of this problem is figuring out how to compute the probability that two randomly selected numbers between 0 and 1 will have a sum less-than-or-equal-to 1/2. This can be done by depicting the set of all possible outcomes (called the "sample space") as a geometric area, and computing the proportion of that area that constitutes "success" (see Member pictures vol. 3, #623, a picture I uploaded describing this computation.) This technique was first employed by the French mathematician Buffon in 1777 (see To view links or images in this forum your post count must be 2 or greater. You currently have 0 posts. a fascinating problem: equivalent to, "If I drop a pencil on a tile floor, what's the probability it will land so it crosses one of the cracks between the tiles?")
As Thod has shown by independently devising this technique (hats off to the Braniac!), the probability of winning the game is 1/8. Since we also know the cost to play and the earnings for a win, we can compute the long-term average win/loss value per game. This is called the "expected value" of the game, and is just a weighted average of the payments, where the weights are the probability of each payment:
Probability of a win: 1/8
The change in my cash position for a win: $8 - $1= $7 (prize minus cost to play)
Probability of a loss: 1 - 1/8 = 7/8
The change in my cash position for a loss: $0 - $1= -$1 (prize minus cost to play)
From these facts, we can compute the average change in cash for a game:
(1/8)x($7) + (7/8)x(-$1) = $(7/8) - $(7/8) = 0
In other words, the fee structure of this game is designed for a "break even" outcome over the long-term! This means that if I play this game many times, at the end I can expect my cash position to be virtually unchanged.
To test this result, I wrote a computer simulation that played the game 1 BILLION times (took about 15 minutes on my desktop dual-core machine). The result was that, even though billions of dollars changed hands between the gamer and the house, the net change was only around $500 bucks, for an average change per game of approximately 0.0005 CENTS (1 two-thousandth of a cent). Pretty close to ZERO in my book!
44sunsets
06-08-2008, 06:17 AM
In other words, the fee structure of this game is designed for a "break even" outcome over the long-term! This means that if I play this game many times, at the end I can expect my cash position to be virtually unchanged.
This is a fascinating exercise in probability. You should post this up on a website so it can be archived for posterity.
Monte314
06-08-2008, 12:09 PM
I teach both undergraduate and graduate statistics, and my students *love* this stuff. Somehow, embedding the treatement of abstract concepts (such as computing probabilities as ratios of areas) in stories really engages people.
vBulletin® v3.8.7, Copyright ©2000-2013, vBulletin Solutions, Inc.