This problem is in Contest(s) below:
Contest 1056:2021模拟练习5
Contest 1278:ACM训练题 二(大二)