S=list(input())
l="keyence"
for i in range(len(S)):
    if S[i] in l:
        pass
    else:
        S[i]="*"

lst=[]
flag1=True
#print(S)
f=len(S)+2
for i in range(len(S)):
    if S[i]=="*":
        if flag1:
            f=i
            g=i
            flag1=False
        else:
            g=i

for i in range(len(S)):
    if f<=i and i<=g:
        continue
    lst.append(S[i])
flag=False
for i in range(len(lst)):
    if (i+6)>=len(lst):
        break
    tmp=""
    for j in range(7):
        tmp=tmp+lst[i+j]

    if tmp==l:
        print("YES")
        exit()
print("NO")