s = list(input())
memory = 0
moku = list("keyence")
hantei = 0
ren = 0
for i in range(len(s)):
    if hantei >= 2:
        break
    if s[i] == moku[memory]:
        memory+=1
        if ren == 0 and i!=0:
            hantei+=1
        ren+=1
    else:
        ren = 0
if memory == 7:
    print("YES")
else:
    print("NO")