Friday, June 7, 2013

project euler problem 212

Combined Volume of Cuboids

This is an interesting problem. My old code used an inefficient algorithm(although the basic idea is in the right direction). It takes minutes to get the answer. 

The discussion is very interesting. Robert_Gerbicz gave a very efficient algorithm that I missed. I wrote my code using the same idea, it only needs 80 ms while a lot of people needs 10 seconds to minutes to get the answer. Thank you Robert,  for giving me a different view of the problem. 

No comments:

Post a Comment