Codeforces Round #263 (Div. 1)

题目:http://codeforces.com/contest/461
【Codeforces Round #263 (Div. 1)】题解:http://codeforces.com/blog/entry/13568

    推荐阅读