> > Igor (the problem author) did that too, but without the panic since he had > a little more time. :-) > > Yes, I actually implemented a complicated Dynamic Programming solution, in rational numbers, with BigInteger. It had an exponential running time. And then I spend a long time looking for the bug, when I saw that the answers were always coming out as integers.
Of course, it didn't help that there were no input limits given to me, so I did not know whether there was a polynomial-time solution or not. David Arthur was actually first to formally prove that the simple solution was always correct. He wrote the problem analysis. igor -- You received this message because you are subscribed to the Google Groups "google-codejam" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-code?hl=en.
