s = input()
a = 'keyence'
flag = 1

for i in range(8):
    if a[0:i] in s:
        firstindex = s.index(a[0:i])
        if a[i:8] in s[firstindex:]:
            secondindex = s.index(a[i:8])
            
            if s.replace(s[firstindex+i:secondindex],'') == a:
                print('YES')
                flag = 0

if flag == 1:
    print('NO')