s = input()
w = list("keyence")

st = ""
i_w = 0
delete = []

for i in s:
    if i == w[i_w]:
        i_w += 1
        if not st == "":
            delete.append(st)
            st = ""
    else:
        st += i
else:
    if not st == "":
        delete.append(st)

if i_w == 7 and len(delete) <= 1:
    ans = "YES"
else:
    ans = "NO"
print(ans)
