100 floors with 2 eggs puzzle
There is a building of 100 floors If an egg drops from the Nth floor or above it will break. If it’s dropped from any floor below, it will not break. You’re given 2 eggs. Find N, while minimizing the number of drops for the worst case.
First thought which comes to our mind is to use binary search, we first drop Egg#1 from 50th floor, if it does not break, then try the middle of second half, if breaks then we have to try each floor in first half. But this will give worst case number of drops as 50(if it brakes on 50th floor, then we have to try from 1 to 49 floors sequentially).
Second thought is to try xth floor then 2xth floor till 100th, in this case worst case time will be (100/x)+(x-1). worst case will be when Egg #1 breaks at 100th floor then we have to try Egg #2 from (100-x)th to 99th floors. In (100/x) + (x-1) equation, with increase in x, 100/x decreases while (x-1) increases, thus we can minimize it when 100/x = (x-1), this gives x ~10, which gives worst case number as 19 drops.
But increasing the floor every time by x is not a very nice idea, as with each new increase in Egg #1 drop, we should decrease Egg #2 drops to minimize worst case number. so if we drop Egg #1 from xth floor initially, then in next turn we should try x + (x-1)th floor(to keep the worst case number same).
Thus we can say X + (x-1) + (x-2)…1 = 100
X(X+1)/2 = 100 => X=14.
So we should drop Egg #1 from 14th, then 27th, then 39th and so on.
Your Answer
More puzzles to try-
Tree and vine riddle
There is a tree 20 feet high, with a circumference of 3 feet. A vine starts at the base of ...Read More »Srabon wanted to pass
The result of math class test came out. Fariha’s mark was an even number. Srabon got a prime!! Nabila got ...Read More »Hhow many books are on the shelf?
There are several books on a bookshelf. If one book is the 4th from the left and 6th from the ...Read More »Dinosaur days
Imagine you are in the ancient days of the dinosaurs, and one dinosaur is chasing after you. What do you ...Read More »Doughnut Distribution
Assume the given figure to be a delicious doughnut. Yes, now you can concentrate more on the puzzle. So you ...Read More »Fluttering Flocks
Hidden in each of the sentences below is the name of a bird. Can you find them all? Hint: The ...Read More »How did they get the barley from one sack to the other without pouring the grain somewhere else?
Poor farmer went to the farmers market to sell his corn. He had only one sack so he put barley ...Read More »Who is the murderer?
Role Action Block Prevents the target player from acting Redirect Change target player target. Save Protects the target player from ...Read More »How will you program it to work?
The LCD device should be able to tell the right time in the format HH:MM:SS in 12-hour format. You can ...Read More »Watermelon in the sun math riddle
There is a 100 pound watermelon laying out in the sun. 89 percent of the watermelon’s weight is water. After ...Read More »How many 6 digits can be formed puzzle
How many six digit numbers can be formed using the digits 1 to 6, without repetition such that the number ...Read More »Cake distribution among 5 puzzle
In a party, there are five people and a whole round cake lying at the center of table. Only four ...Read More »Little Tommy
Little Tommy Tittle tat took two Ts, to tie two ups to two tall trees, to torment the terrible tittle ...Read More »How many seconds in a year
How many seconds are there in a year? Hint: You don’t need a calculator the seconds in ...Read More »Math Book Say
What did one math book say to the other math book?Read More »Akbar birbal puzzle
Akbar summoned Birbal out of anger. He told him that he will have to face death. He asked him to ...Read More »Is it True?
The following question it puts forth to you: 25 – 55 + (85 + 65) = ? Then, you are ...Read More »How can this be possible ?
Adam and his wife were living in a rural place. On a certain day, Adam wife fell ill and he ...Read More »Months Puzzle
In a year there are 12 months. 7 months have 31 days. How many months have 28 days?Read More »Why not?
A bus driver was heading down a street in Delhi. He went right past a stop sign without stopping, he ...Read More »