s = input()
target = 'keyence'
s_len = len(s)
flg = 0

for i in range(7):
    target1_ind = -1
    target1 = target[0:i]
    target2 = target[i:7]
    if target2 == target:
        if target in s:
            if s.index(target) == 0 or s.index(target)+7 == s_len:
                flg = 1
    else:
        if target1 in s and target2 in s:
            if s.index(target1) == 0 and s.index(target2)+len(target2) == s_len:
                flg = 1

if flg == 1:
    print('YES')
else:
    print('NO')
