Wednesday, September 14, 2005

A Game of Second Chance

OK, so, I watch this TV show called Numbers and I learned this math thing while watching last week. Check out this demonstration first, then read the following and PLEASE share you comments:

Cup and Bean Game

I wrote the game in ColdFusion hoping to prove to my wife and other non-believers that the math I learned is correct. Here is how it goes. . .

The game master hides the bean under one of three cups.

You choose one of the cups where you think the bean is.

The game master reveals that the bean is NOT under one of the OTHER TWO cups that you did not choose.

The game master now tells you that, if you want, you can change your choice of where you think the bean is.

You change or reaffirm your choice.

The game master reveals where the bean is.

That's the game.

Here's the math, in lay man's terms--the only terms I know for it. . .

At the start of the game, you don't know where the bean is, you have a 2 out of 3 chance of getting it wrong.

When the game master reveals one of the cups you did NOT choose, you have an opportunity to change your choice. The math says you should change your choice.

See, in the first choice, you were more likely to have chosen the wrong cup. Now, at the opportunity to change your choice, you should know very well the odds are that the previous choice was wrong.

Sure, there is a 1 in 3 chance that you were right--but odds are odds, and 2 in 3 wrong still beats 1 in 3 right.

The game is not over, you know that there is a greater chance that you first choice was wrong than it was right. When faced with the new, seemingly 50/50, choice you should abandon the likely wrong first choice.

If I were a math wiz, I'd explain all this in those terms, but that would probably make even less sense to many of us. So, just play the stupid game as many times as you want and see for yourself. If you don't trust my code, download it here or just play the game with a friend over and over again with real playing cards (where's the ace?) or any other analogy. I've played the game many times and have never won less than 7 out of ten games when consistently changing my choice on the second chance. My wife tried it out and she maintained her choice every time and never won more than 3 games out of 10.

But no one believes me!! That second choice really throws people off.

If anyone has a more eloquent way of explaining this--or better yet, has a transcript of what the guy on Numbers said--please share it here in a comment.

Also, any other code monkeys out there are welcome to chime in on my code--especially if there is a flaw.

Thanks

4 comments:

Laura said...

Out of 11 I only won two, most of the time I maintained my first choice. I'm stubborn that way.

David said...

Yeah. I'm talking with people at work about this. The odds of winning when changing your choice seem only marginally better, but they are better. If you keep playing and keep leaving your first choice, you will see that sometimes it looks as though you are not doing so poorly.

If I knew the math, I would figure out what the odds are in every possible scenario of the game. I'm guessing the odds, when you change your choice every second chance, are somewhere better than 50/50 and barely worse than 2/3.

Thanks for playing and chiming in!

David said...

Here is a great article on how this very issue caused a lot of controversy for some other people. I'm pretty sure the scenario they describe is exactly what I saw on the show Numb3rs on TiVo. It's goes, three doors, two goats and a car. . .

It also seems to conclude that if you don't change your choice, you have a 1 in 3 chance of winning and if you DO change your choice, you have a 2 in 3 chance of winning. Much more. . .stable? than I thought, but here's the math I've been looking for:

from some "Math Dept Home Page

"Let Ci denote the event that the car is at door i, and Hj the event that the host opens door j. Then

P(You win the car if you switch)

= P(H3 C2) + P(H2 C3) = P(C2)P(H3|C2) + P(C3)P(H2|C3) = (1/3)·1+ (1/3)·1 = 2/3

and in similar manner we find that

P(You win the car if you don't switch) = (1/3)·p + (1/3)·(1 - p) = 1/3

where p = P(H2|C1)."

David said...

As far as I'm concerned, this is settled:

Latest Post. . .Wikipedia