num_list = input()
key = 'keyence'

i = 0
ans =False
while num_list[i]==key[i]:
    i+=1
n = i
if n >= 6:
    print('YES')
else:
    print('NO')


i = -1
while num_list[i]==key[i]:
    i -= 1
    n += 1

if n >= 6:
    print('YES')
else:
    print('NO')