This problem is in Contest(s) below:
Contest 1385:【算法设计与分析】实验二
Contest 1394:【算法设计与分析】实验2 递归与排列问题求解
Contest 1520:算法实验2