s=input()
pp="keyence"
j=0
cnt=0
p=0
for i in range(len(s)):
	if s[i]==pp[j]:
		j+=1
		if cnt==1:
			p=1
			cnt=0
	else:
		cnt=1
		if p==1:
			p=2
			break
	if j==6:
		if p==0:
			break
		else:
			if i==len(s)-1:
				break
			else:
				p=2
				break
if j==6 and p<=1:
	print("YES")
else:
	print("NO")