Hacker News new | past | comments | ask | show | jobs | submit login
Coding Horror: The Problem of the Unfinished Game (codinghorror.com)
12 points by twampss on Dec 31, 2008 | hide | past | favorite | 31 comments



Yeah, this is a famous puzzle. The answer is supposed to be 2/3, because what the question is asking you to do is consider all the parents in the world where at least one of the two children is a girl. Then you're left with 3 possibilities, BG, GB and GG.

If you phrase the question like that, everyone will get the right answer. The reason people get it wrong is that people don't normally talk like that. Imagine you're at a party, and someone tells you they have two kids, and "one of them is a girl." Clearly, they mean that the other is a boy, which means the answer is 100%.

But the most intuitive way of interpreting the question is that you know that a specific child is a girl, say because the person brought one kid to the party, who turns out to be a girl. With this interpretation, the obvious answer of 50% is in fact correct.

You often hear the complaint that people don't understand math. In this instance, however, an equally valid way of explaining what's going on is that mathematicians don't understand people.

This criticism applies partially to the normal game-show version of the Monty Hall problem, but I think there the wording is genuinely ambiguous regarding the host's behavior, and my answer would be "not enough information."


The BG vs GB thing is difficult to understand. But easier to understand is that 50% of two child familes are mixed gender, while 50% are same gender. With 40 families having two children, 20 will have a boy and a girl, and 20 will have either two boys or two girls. Of the same gender familes, 50% (10) will be boy/boy and 50% (10) will be girl/girl. If you learn that a particular family has a daughter, then you know that family isn't one of the 10 families with two boys. This leaves 30 families, 20 of which (or 2/3) have one boy.

Likewise, for some reason the Monty Hall problem is hard to understand in three door form. But if you change the problem to 100 doors, and explain that Monty's assistant closes 98 bad doors, it's easier (at least for me) to see that the original guess had a 1/100 chance of being right, while the other door is 99/100 likely to be the right one.


> You often hear the complaint that people don't understand math. In this instance, however, an equally valid way of explaining what's going on is that mathematicians don't understand people.

This is by far the most insightful thing I have ever read about this problem. Furthermore, this being a site about startups, I would say that you will be more successful if you understanding people and math than if you just understand math.


That's a good point and there a lot of people who are very good at math, but hate word problems with a passion.


The game-show version of the Monty Hall problem isn't ambiguous... people even had the chance to see the show before knowing the mathematical problem. I agree there are different ways to state the problem, but the wording doesn't explain why it confuses people.


Actually, the strongest criticism that I've heard about the Monty Hall problem is that the game show didn't actually work like that.

I've tried explaining the problem to both people who've seen the show and those who haven't. My experience is that if you've seen the show you'll never accept the question, let alone the answer. Meanwhile, those who never watched the show can be convinced.


Take a random parent with two children. You ask them if at least one is a boy and they say yes. The probability that the other is a girl is 66.6%

Take another random parent with two children. You ask them if the oldest child is a boy and they say yes. Now the probability that the other is a girl is 50%.

This confuses people. (The point is the second scenario gives you more information since it's a subset of the first.)


Exactly correct. Your comment should be at the top of this discussion. It took me forever to figure the above out when I first ran into this puzzle in 7th grade.

And although this problem is often used to show that humans are bad at doing probability in their heads, note how simple it is to do the probability calculation for the two scenarios that you've mentioned.

What's actually hard for humans is describing models or simulations, not doing the probability. Once you explained the possibilities for original problem in a more detailed way, the answer(s) becomes obvious.


This is easier to understand if you start by listing all of the possibilities.

  Two boys:        BB
  Two girls:       GG
  Boy, then girl:  BG
  Girl, then boy:  GB
So there are four possibilities: (BB, GG, BG, GB).

If you know that one of the children is a girl, then BB is impossible and you can remove it from the list. This leaves only 3 possibilities (GG, BG, GB).

This is the set you use to calculate the probability and there are two ways out of three that the person could have both a boy and a girl: BG and GB

That gives you 2/3 or 67%


There are neither 4 nor 3 possibilities: it was given that one child is a girl. So it's either GB or GG. 50% FTW.


67%. The percentage of having one boy and one girl is 50%, "one of them is a girl" eliminate the condition of having two boy.


Except that real data seems to disagree with you - the chance is about 50%.

http://www.in-gender.com/xyu/Odds/Gender_Odds.aspx


A link to an analysis based on an actual study was modded down?

Who are you people and what did you do to HN.


The analysis you linked to does not refute anything said here. In fact, the conclusions of the study you showed are a necessary assumption for this problem (that each gender has an equal probability and independent of birth order). This problem has nothing to do with biology but rather using posterior information to come up with a probability given a statistical experiment.

However, I did not vote you down.


But why does it necessarily have nothing to do with biology? It seems you've added a condition to the question that does not exist. Additional data points are quite useful, and using them to find the correct "real world," outcome seems most logical.


It was modded down because it has nothing to do with the statistical riddle, read the other comments and you'll see why it's 66%.


+1: The Monty Hall Problem Never Gets Old :)


Is not each birth an independent random event, and thus the likelihood that they would have a boy, given that they already have a girl, simply 50%?


The correct answer is 2/3 though. Check the Monty Hall problem for the explanation (this kind of problem is well known for having confused famous mathematicians like Erdös himself).


That's the same reasoning I have. P(B|A) = P(B) for independent variables.


On the other hand, if a couple told you they had five kids, at least four are boys, you would say to yourself, "it's not very likely that any couple would have five boys", and you would be correct...


You would be, as long as you don't say "it's therefore unlikely the fifth child is a boy".


Yes, BBBBB is rare. But BBBBG is just as rare (at least statistically. In practical terms, I suspect that having four boys in a row would be too exhausting and irritating, so they'd have given up by then).


Yeah, unless they have a lot of yard work they need done. Anyway, {BBBBG,BBBGB, BBGBB, BGBBB, GBBBB} is less rare.


> Yes, BBBBB is rare. But BBBBG is just as rare

Actually, it isn't. More boys are born than girls. (However, boys are somewhat more likely to die young.) Also, the odds for a given mating pair are not the same as the odds for the population as a whole.

And then there's post-conception sex-selection....


If the problem were "Given an ordered number of events (birth) what is the probability distribution of the last event". Then yes, it would be 50/50.

But you're looking for at least one boy. If you had 1000 children, intuitively, the probability of at least one being a boy is huge.


Consensus is clearly 66% or 50% depending on whether you think the GB and BG combinations are the same thing in the context of the question.

But isn't it true that more boys than girls are born (because boys die younger so evolution tries to balance it out a bit)?

Does anyone know if certain fathers can only produce one sex of child? If so then having one girl would increase the chances of having another girl slightly.


Evolution doesn't try to balance anything - evolution is not a person, and it doesn't think.

There is a slight difference in the swimming speed of XX vs XY sperm, which accounts for the difference. Also I believe females have a slightly better survival ratio, the reasons are complicated, but include the fact that all fetuses start as female, and then are modified by testosterone to be male, i.e. female is the default. Plus females have XX so some genes are doubled which helps them.

It's pretty much impossible for a father to make just one or the other because of that way it's produced.

The father has XY cells, which split in half to make sperm, one half become a male sperm the other female. So sperm is always made in pairs.

There can be differences in the mother that affect one or the other differently though (PH for example, and the sperm are not the same size).


I wasn't suggesting that evolution thinks, I was suggesting that we've evolved to produce more males so that there's an optimum 50/50 balance of the number of males and females at around early adulthood. Considering some of the other things that evolution has achieved that seems like a pretty reasonable thing to suggest.

Your explanation of whether certain couples can only produce males or females was pretty interesting though, thanks.


I don't think that reason (males die younger) explains it.

Although women may live longer they lose their ability to reproduce earlier so I would expect more girls than boys.


If it's fifty-fifty between genders, and each birth is an independent event, but a boy + girl is like umm.. a chain of independent events or something?

My guess is 25% - 0,5 times 0,5..

But what exactly is the right answer? There doesn't seem to be a consensus yet.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: