s=input()
t="keyence"
n = len(s)
m = len(t)
dp = [[0 for i in range(m+1)] for j in range(n+1)]
for i in range(n):
    for j in range(m):
        if s[i]==t[j]:
            dp[i+1][j+1]=dp[i][j]+1
        else:
            dp[i+1][j+1]=max(dp[i][j+1],dp[i+1][j])
if dp[n][m]!=7:
    print("NO")
    exit()
for i in range(1,7):
    z=[t[:i],t[i:]]
    #print(z)
    for j in range(n):
        y=[s[:j],s[j:]]
        print(y)
        if z[0] in y[0] and z[1] in y[1]:
            print("YES")
            exit()
if t in s:
    print("YES")
    exit()
print("NO")