codeforces 213, topcoder 597