Presentation is loading. Please wait.

Presentation is loading. Please wait.

Google/Microsoft interview. Problem 1 Estimate the weight of a 747.

Similar presentations


Presentation on theme: "Google/Microsoft interview. Problem 1 Estimate the weight of a 747."— Presentation transcript:

1 Google/Microsoft interview

2 Problem 1 Estimate the weight of a 747.

3 Problem 1 Estimate the weight of a 747. Ok, 747 is a vehicle designed to carry people. We don’t know much about planes, but let’s think by proxy. What other large vehicles carry passengers? Busses. Assume 747 = 6 buses. 4 in a row + 2 on top. Each bus ~ 60 people. So 747 ~ 360 people. Sounds about right. A bus weighs 5-10 tons. So, a 747 weighs between 6*5 and 6*10 = 30-60 tons. (43 tons, actually).

4 Problem 2 In a country where couples want boys, they use the following strategy: couples have children until they have a boy, then stop. What is the ratio of boys to girls in this country?

5 Problem 2 In a country where couples want boys, they use the following strategy: couples have children until they have a boy, then stop. What is the ratio of boys to girls in this country? 1 St step: get your feet wet. Play with the problem. Start with N=2 couples. You can have 2 boys. Or you can have 4 girls and then 2 boys. So, looks like all possible ratios are possible.

6 Problem 2 In a country where couples want boys, they use the following strategy: couples have children until they have a boy, then stop. What is the ratio of boys to girls in this country? 1 St step: get your feet wet. Play with the problem. Start with N=2 couples. You can have 2 boys. Or you can have 4 girls and then 2 boys. So, looks like all possible ratios are possible. Of course, each of these outcomes has its own different probability. So, we could consider all outcomes and work out the probabilities. But that would be kind of difficult…

7 Problem 2 In a country where couples want boys, they use the following strategy: couples have children until they have a boy, then stop. What is the ratio of boys to girls in this country? Alternative. Let’s go to the large N limit. Appropriate for “country”. Will simplify things. Exactly ½ couples will have boys, ½ will have girls. Draw a BIG diagram.

8 Problem 2 couples Offspring generation # N/2 BBBBBBBBBBBBB GGGGGGGGGGGGG 1 2 3 BBBBBB GGGGGG N/4 N/8 BBB GGG After each generation, the ratio of B:G = 1:1


Download ppt "Google/Microsoft interview. Problem 1 Estimate the weight of a 747."

Similar presentations


Ads by Google