while True:
    n = int(input())
    if not n:
        break
    print(n//2)

等价于凑够2空瓶就能换1瓶汽水,等价于求空瓶数除以2的模型,即:n//2