|
|
back to boardHint If your complexity is O(N^3) and your solution only gets AC in C/C++ then maybe you should print the matrix of where is best to drop the first egg. Re: Hint Posted by keivan 29 Jan 2013 17:07 If your complexity is O(N^3) you can use the fact that when number of eggs >= log(N) , answer is log(N) . O(N^2*log(N)) . Re: Hint Posted by Gary Ye 25 Aug 2014 04:25 If your complexity is O(N^3) you can use the fact that when number of eggs >= log(N) , answer is log(N) . O(N^2*log(N)) . Keivan, that's such a good observation! Is that the intended solution though? |
|
|