This problem is in Contest(s) below:
Contest 6280:基础C-第12课-课堂练习(王)
Contest 6199:基础C-第10课-课堂练习(国)