This problem is in Contest(s) below:
Contest 1058:1106、1113少年宫三、四
Contest 1057:质数系列1
Contest 1215:质数系列1