Skip to content

Latest commit

 

History

History

151-cracking-eggs

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Cracking eggs

Challenge Description:

You have a N story building and K eggs. They are especially strong eggs so they're able to withstand impact up to a certain number of floors.

Your goal is to identify the number of drops you need make to determine number of floors it can withstand.

Input sample:

The first argument will be a path to a filename containing a space separated list of 2 integers, first one is number eggs, second one - number of floors. E.g.


2 100

Output sample:

The output contains one integer - the worst worst case upper bound on the number of drops you must make to determine this floor.

14