If an egg is dropped and does not break it is undamaged and can be dropped again.
2 identical eggs highest floor to drop.
Both eggs are identical.
With that you will come to know the highest floor from which you can drop without breaking.
If an egg is dropped and does not break it is undamaged and can be dropped again.
Suppose that we wish to know which stories in a 100 story building are safe to drop eggs from and which will cause the eggs to break on landing.
The following is a description of the instance of this famous puzzle involving 2 eggs and a building with 100 floors.
Let s talk about the 2 egg problem courtesy of interview cake.
The aim is to find out the highest floor from which an egg will not break when dropped from a floor.
Generic solution if the building has n floors then take the first egg and drop it from sqrt n 2 sqrt n 3 sqrt n and so on.
Let s suppose if it breaks on 18th floor take the second egg and drop it from 13th floor till 17th floor.
The aim is to find out the highest floor from which an egg will not break when dropped out of a window from that floor.
You are given two eggs and access to a 100 storey building.
A building has 100 floors.
You are given 2 eggs you have access to a 100 storey building eggs can be very hard or very fragile means it may break if dropped from the first floor or may not even break if dropped from 100 th floor both eggs are identical you need to figure out the highest floor of a 100 storey building an egg can be dropped without breaking.