S = list(input())
KEY = list('keyence')
L = len(KEY)
idx = 0
cnt = 0
flg = False
for s in S:
  if idx <= L-1 and s == KEY[idx]:
    idx += 1
    flg = False
  else:
    if not flg:
      cnt += 1
      flg = True
    
if idx == L and cnt <= 1:
  print('YES')
else:
  print('NO')
