This problem is in Contest(s) below:
Contest 1065:从星开始学循环
Contest 1066:程序设计五星活动认证赛-2024