This problem is in Contest(s) below:
Contest 1229:暑期C++编程训练A3
Contest 1230:暑期C++编程训练B3