n = int(eval(input()))

n %= 10

if n == 3:

  print('bon')

elif n == 0 or n == 1 or n == 6 or n == 8:

  print('pon')

else:

  print('hon')
n = int(eval(input()))

n %= 10 

if n == 3:

    print('bon')

elif n in [0, 1, 6, 8]:

    print('pon')

else:

    print('hon')
n = int(eval(input()))
n %= 10
if n == 3:
    print("bon")
elif n == 0 or n == 1 or n == 6 or n == 8:
    print("pon")
else:
    print("hon")

n = int(eval(input()))
n %= 10
if n == 3:
    print("bon")
elif n in [0, 1, 6, 8]:
    print("pon")
else:
    print("hon")

-elif n == 0 or n == 1 or n == 6 or n == 8: +elif n in [0, 1, 6, 8]: