for(;l=readline();)print(/ 1| 2$|6 /.exec(l)?'POOR':'1 2 3 4 5 6 Do it!!'.replace(eval('/['+l+']/g'),' '))