Easy | Discrete Maths |

There are 10 black socks and 10 white socks (no left-right distinction) in the wardrobe. Your task is to draw the minimum number of socks at random to be sure you have a pair of a single color. How many socks should you draw?

Hint

Pigeonhole principle

Answer

3

Solution

This is the easiest example of a very powerful tool called the Pigeonhole principal, which says that if there are (N+1) pigeons to fit in N holes, atleast one hole will have 2 or more pigeons. Hence, if you pick 3 socks to come with 2 color categories, at least one category will have 2 or more socks, i.e. a pair is guaranteed with either red or black color.

Source: Common

Enable Like and Comment Easy | Discrete Maths |

Assuming that temperature varies continuously, prove that there are always two opposite points on the Earth's surface that have the same temperature.

Solution

Aritro Pathak: consider any great circle.. T(x) is the temp at the point x .. let f(x)=T(x)-T(x+pi), then f(0)=T(0)-T(pi)..f(pi)=T(pi)-T(2pi)=T(pi)-T(0) then f(0) and f(pi) have different signs, so using mean value theorem, you have that f is 0 at some point.

FunFact: There are uncountable number of such pairs.

Here is a video explanation:

https://www.youtube.com/watch?v=5Px6fajpSio

An alternate version of this puzzle is the Mountain Man

http://www.techinterview.org/post/521419748/mountain-man

FunFact: There are uncountable number of such pairs.

Here is a video explanation:

https://www.youtube.com/watch?v=5Px6fajpSio

An alternate version of this puzzle is the Mountain Man

http://www.techinterview.org/post/521419748/mountain-man

Source: Top Quant Interview

Enable Like and Comment Easy | Probability |

Probability of accidents on a road in one hour is 3/4. What is the probability of accidents in half hour?

Hint

The probability of no event in two disjoint intervals of half hours is same as probability of no event in one full hour.

Answer

1/2

Solution

Probability of no accident in 1 hour = (prob of no accident in 1/2 hour )*(no accidents in next disjoint 1/2 hour)=p^2

hence 1/4=p^2, hence p=1/2, hence probability of accident in half hour=1/2

Read Palak's detailed solution:

Assuming things to be memoryless, and thus disjoint time intervals to be independent, prob. of no accidents in [0,2t) = prob. of no accidents in [0,t) AND [t,2t) => 1-p(2t) = (1-p(t))^2, where p(t) is the prob. of accident in time interval of length t. Given that p(1h)=3/4 => p(0.5h)=1/2 and p(2h)=15/16.

The way we have defined p(t) above, it is the probability that at least 1 accident happens in time interval t. Thus, as t increases, p(t) increases.

If, instead, p(t) is defined as the fraction of vehicles that met with an accident in time interval t, then again p(2t)=p(t)+(1-p(t))*p(t)=1-(1-p(t))^2

hence 1/4=p^2, hence p=1/2, hence probability of accident in half hour=1/2

Read Palak's detailed solution:

Assuming things to be memoryless, and thus disjoint time intervals to be independent, prob. of no accidents in [0,2t) = prob. of no accidents in [0,t) AND [t,2t) => 1-p(2t) = (1-p(t))^2, where p(t) is the prob. of accident in time interval of length t. Given that p(1h)=3/4 => p(0.5h)=1/2 and p(2h)=15/16.

The way we have defined p(t) above, it is the probability that at least 1 accident happens in time interval t. Thus, as t increases, p(t) increases.

If, instead, p(t) is defined as the fraction of vehicles that met with an accident in time interval t, then again p(2t)=p(t)+(1-p(t))*p(t)=1-(1-p(t))^2

Source: Placement tests

Enable Like and Comment Easy | Probability |

Suppose you're on a game show, and you're given the choice of three doors: Behind one door is a car; behind the others, goats. You pick a door, say No. 1, and the host, who knows what's behind the doors, opens another door, say No. 3, which has a goat. He then says to you, "Do you want to pick door No. 2?". What is the probability to win car if you switch?

Answer

2/3

Solution

Probability that your initial choice did not have car is 2/3. So you should switch to the other gate, and win the car with probability 2/3

Easy | Strategy |

100 prisoners are lined up and assigned a random hat, either red or blue. There can be any number of red hats. Each prisoner can see the hats in front of him but not behind. Starting with the prisoner in the back of the line and moving forward, they must each, in turn, say only one word which must be "red" or "blue". If the word matches their hat color they are released, if not, they are killed on the spot. They can hear each others answers, no matter how far they are on the line. A friendly guard warns them of this test one hour beforehand and tells them that they can formulate a plan where by following the stated rules, 99 of the 100 prisoners will definitely survive, and 1 has a 50/50 chance of survival. What is the plan to achieve the goal?

Hint

Red and blue can be thought of as 0 and 1. Think of modulo 2 sums now.

Solution

Number prisoners from 100 to 1, with 100 being the last person in line, being able to see 99 other hats. Prisoners agree that if the number of red hats that the 100th person can see is even, then he will say “red”. if they add up to an odd number, he will say “blue”. this way number 99 can look ahead and count the red hats. if they add up to an even number and number 100 said “red”, then 99 must be wearing a blue hat. if they add up to an even number and number 100 said “blue”, signalling an odd number of red hats, number 99 must also be wearing a red hat. number 98 knows that 99 said the correct hat, and so uses that information along with the 97 hats in front to figure out what color hat is on 98’s head.

Latest solved Puzzles

Color Switches Weird Sequences Intersecting Pillars Consecutive sums Scaling a Square Difficulty Level

© BRAINSTELLAR |