def getN():
    return int(input())

def getMN():
    a = input().split()
    b = [int(i) for i in a]
    return b[0],b[1]

def getlist():
    a = input().split()
    b = [int(i) for i in a]
    return b

sin = input()
key = "keyence*"
ans = "YES"
i = 0
miss = False
cont = False
for c in sin:
    if i <= 7 and c == key[i]:
        i += 1
        if miss:
            cont = False
    elif not miss:
        miss = True
        cont = True
    else:
        if not cont:
            ans = "NO"
            break

if i != 7:
    ans = "NO"
if sin[-7:] == "keyence":
    ans = "YES"

print(ans)