📌  相关文章
📜  谜题 17 | (在一个人们只想要男孩的国家里,男孩和女孩的比例)

📅  最后修改于: 2022-05-13 01:57:25.267000             🧑  作者: Mango

谜题 17 | (在一个人们只想要男孩的国家里,男孩和女孩的比例)

在一个国家,所有家庭都想要一个男孩。他们一直生孩子,直到男孩出生。该国男孩和女孩的预期比例是多少?

解决方案:
假设:生男孩或女孩的概率相同。此外,下一个孩子是男孩的可能性并不取决于历史。

这个问题可以通过在男婴出生之前计算预期的女孩数量来解决。

Let NG be the expected no. of girls before a boy is born

Let p be the probability that a child is girl and (1-p)
be probability that a child is boy.

NG can be written as sum of following infinite series.

NG = 0*(1-p) + 1*p*(1-p) + 2*p*p*(1-p) + 3*p*p*p*(1-p) + 4*p*p*p*p*(1-p) +.....

Putting p = 1/2 and (1-p) = 1/2 in above formula.

NG    = 0*(1/2) + 1*(1/2)2 + 2*(1/2)3 + 3*(1/2)4  +  4*(1/2)5 + ...
1/2*NG = 0*(1/2)2 + 1*(1/2)3 + 2*(1/2)4 + 3*(1/2)5  +  4*(1/2)6 + ...

NG - NG/2 =  1*(1/2)2 + 1*(1/2)3 + 1*(1/2)4 + 1*(1/2)5  +  1*(1/2)6 + ...

Using sum formula of infinite geometrical progression with
ratio less than 1
NG/2 = (1/4)/(1-1/2) = 1/2

NG = 1

所以预期的女孩数量 = 1

由于女孩的预期数量是1,而且总是有一个男婴,所以男孩和女孩的预期比例是50:50