Test cases for problem 489 weren't good enough. Some wrong submissions managed to get AC. We've added some critical test cases and increased input size significantly.
Thanks to Tirian for the report!
489
Moderator: Carlos