This problem is in Contest(s) below:
Contest 1241:1125队内测试
Contest 1156:c++0414练习1400-1410
Contest 1157:python-0414练习1400-1410