Codeforces. Problem #234.B solved