i = int(input())

while i != 0:
    i = i % 10
    if i == 0:
        print('pon')
    elif i == 1:
        print('pon')
    elif i == 2:
        print('hon')
    elif i == 3:
        print('bon')
    elif i == 4:
        print('hon')
    elif i == 5:
	print('hon')
    elif i == 6:
	print('pon')
    elif i == 7:
	print('hon')
    elif i == 8:
	print('pon')
    elif i == 9:
	print('hon')

    i = int(input())
