Can I read Two Eggs and 100 Floors Puzzle Solution on EtoBox?
Two Eggs and 100 Floors Puzzle Solution by Karthikeyan Viswanathan is a document available to read on EtoBox.
What is Two Eggs and 100 Floors Puzzle Solution about?
To solve the 2 eggs problem optimally with the fewest number of drops requires using a combination of binary search with the first egg followed by linear search with the second egg if needed. The optimal solution is to drop the first egg from floors that are increments of 14 (14, 27, 39, etc.), using it to narrow the search range in a binary fashion. If the first egg breaks, then linear search is used with the second egg to fully determine the floor. This solution requires a maximum of 14 drops.
- Author
- Karthikeyan Viswanathan
- Language
- EN