N=input()
kye="keyence"
Nlen=len(N)
flag=0
i=0
x=0
if Nlen== N==kye:
    flag==1

if N[0]==kye[0]and flag==0:
    while flag==0 and N[i]==kye[i]:
        i=i+1
        if i==7:
            flag=1
    x=i
    while flag==0 and N[x]!=kye[i]:
        x=x+1
        if x==Nlen:
            flag=2
    
    if N[x:]==kye[i:]:
            flag=1
else:
    while flag==0 and N[x]!=kye[i]:
        x=x+1
        if x==Nlen:
            flag=2
    
    if N[x:]==kye:
            flag=1



if flag==1:
    print("YES")
else:
    print("NO")