T = "keyence"
S = input()

def f(i, j):
    if j == 6:
        return True
    if i == len(S):
        return False
    if S[i] == T[j]:
        return f(i+1, j+1)
    else:
        return g(i+1, j)

def g(i, j):
    if i == len(S):
        return False
    if S[i] != T[j]:
        return g(i+1, j)
    else:
        return h(i+1, j+1)

def h(i, j):
    if j == 6:
        return True
    if i == len(S):
        return False
    if S[i] == T[j]:
        return f(i+1, j+1)
    else:
        return f(i+1, 0)

print("YES" if f(0, 0) else "NO")
