Interviewing Question: The Eggs and the Tower
Posted by archworx on February 19, 2007
Think of this, you have a building which is 100 floors high and you have 3 eggs. You can throw an egg from any floor and it might or might not break, but there is a certain floor (a threshold floor) afterwhich eggs are guranteed to break for all floors above this certain floor. If We want to know exactly which floor is the threshold floor, what is the minimum number of egg throws do we have do make?
Remember: You have only 3 eggs, so if you break all the 3 eggs without finding the threshold floor then you have failed. Also remember that we want the minimum number of throws.