2 ms·
A) true I think I fell just for premature optimization and made my solution too complicated. I assumed that they would pose the problem in a such a way that the
by Tichy 17y ago
A) true I think I fell just for premature optimization and made my solution too complicated. I assumed that they would pose the problem in a such a way that the naive approach would be too slow.
C) yeah that was the shortest - my first "naive" algorithm was not fast enough, though. I have now thought of a better one and can't wait to try it out, but it is too late for the competition. Still, that alone was worth participating to me - it is a kind of "revelation feeling". I love it when by improving an algorithm a problem becomes solvable.
B) Was actually the easiest for me - the naive algorithm worked well enough. Took me a while to get the program bug free, though...