s=str(input())
i=0
goal='keyence'
index=0
cnt=0
while i<len(s):
  if s[i]!=goal[index]:
    i+=1
  else:
    while index<len(goal) and i<len(s) and s[i]==goal[index]:
      index+=1
      i+=1
    cnt+=1
  if index==len(goal):
    i=len(s)
    break
if index==len(goal) and cnt<=2:
  print('YES')
else:
  print('NO')