import sys
s = input()
time = 0
i = 0
n = 0
for i in range(7):
    if s[i+n] != "keyence"[i]:
        time += 1
        if time >= 2:
            print("NO")
            sys.exit()
        while "keyence"[i] != s[i+n]:
            n += 1
            if i+n >= len(s):
                print("NO")
                sys.exit()
if (len(s)-2 > i+n):
    print("YES")
else:
    print("NO")