s = input()
if s == 'ham':
    print('ham')
else:
    print(s + 'ham')