S = input()

tag = 'keyence'

ans = 0

for i in range(1, 7):
    f_tag = tag[0:i]
    a_tag = tag[i:7]
    f1 = 1
    now = 0
    
    for j in range(len(S)-7):
        for k in range(i):
            if not S[j+k]==f_tag[k]:
                break
        else:
            f1 = f1 + 1
            now = j+i
    
    for j in range(now, len(S)-i):
        for k in range(7-i):
            if not S[j+k]==a_tag[k]:
                break
        else:
            f1 = f1+1
    if f1==3 or (f1==2 and i==0) or (f1==2 and i==7):
        ans =1
    
for i in range(len(S)-6):
    for j in range(7):
        if not S[i+j]==tag[j]:
            break
    else:
        ans = 1
    
if ans==1:
    print('YES')
else:
    print('NO')