import sys

s = input()
A = "keyence"

ind = 100

for i in range(len(s)):
	if i == 0:
		if s[i] == A[i]:
			continue
		else:
			ind = -1
			break

	if i == 6:
		if s[i] == A[i]:
			print("YES")
			sys.exit()

	else:
		if s[i] == A[i]:
			continue
		else:
			ind == i
			break

if ind == -1:
	print("NO")
	sys.exit()

ind_back = 100

for i in range(1,8):
	if i == 1:
		if s[-i] == A[-i]:
			continue
		else:
			ind_back == -1
			break

	if i == 7:
		if s[-i] == A[-i]:
			print("YES")
			sys.exit()

	else:
		if s[-i] == A[-i]:
			continue
		else:
			ind_back == 7-i+1

if ind == ind_back:
	print("YES")
else:
	print("NO")
