Codeforces 166E: Accepted