【題目敘述】https://zerojudge.tw/ShowProblem?problemid=e623
Python code (credit: Amy Chou)
N = int(input())
Round = 1
while N > Round * 4:
N -= 4 * Round
Round += 1
N -= 1 # 方便取餘計算
prize = ["Pen", "Pineapple", "Apple", "Pineapple pen"]
print(prize[N // Round])