This problem is in Contest(s) below:
Contest 1008:华夏理工学院java编程作业3