Big Joke in Educational Codeforces Round 14
contest standing and here is the test case
Codeforces Educational Round 167 Solution Discussion (with Shayan)