import sys
def input(): return sys.stdin.readline().rstrip()
def main():
    s=input()
    ke="keyence"
    cunt=0
    cunt_str=0
    flag=False
    for i in range(len(s)):
        if s[i]==ke[cunt]:
            cunt+=1
            flag=False
        elif cunt_str==0 and flag==False:
            flag=True
            cunt_str+=1
        elif flag==False and cunt_str==1:
            print("NO")
            break
        print(i,s[i],flag)
    else:
        if cunt==7:print("YES")
        else:print("NO")

if __name__=='__main__':
    main()