Interview Riddles

Interview riddles are famous questions asked during interviews by some big companies like Google, Microsoft, Intel etc.

Poisonous Milk Bottle

You are trapped in a room with no food.

After 2 days, you are given 4 bottles of milk out of which one bottle is poisonous.

There is a rat in the room and to find out which bottle is poisonous you can feed milk samples to that rat. But the challenge is that the poison takes effect exactly 10 hours from feeding.

You have only 24 hours in your hand within which you must consume 3 bottles of milk to satisfy your hunger or else you will die.

What strategy would ensure that you drink 3 bottles of milk within 24 hours and survive?

Answer

Feed the rat with milk from one bottle every 1 hour. In this way, if the rat dies after 10 hours, then the first bottle is poisonous.

If the rat does not die after 10 hours, you can drink from milk from the first bottle.

Similarly, if the rat dies after 11 hours, then the second bottle is poisonous, if it dies in 12 hours, the third bottle is poisonous.

However, if the rat doesn’t die even after 12 hours, then the fourth bottle is poisonous and you need not test further.

In this way, you will need a maximum of 12 hours to drink 3 bottles of milk.