#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int , int> P;
typedef pair<ll, ll> PL;
const int INT_INF = 2147483646;
const ll LL_INF = 9223372036854775807;
 
bool SecondCompare(const pair<int,int> &a,const pair<int,int> &b)
{
       return a.second<b.second;
}
 
bool SecondCompareDes(const pair<int,int> &a,const pair<int,int> &b)
{
       return a.second>b.second;
}
 
string s;
int f;
string ans = "keyence";
int pos;
string kou;

int main(){
    cin >> s;
    for(int i = 0; i < s.length(); i++){
        if(pos != ans.length()){
            if(ans[pos] == s[i]){
                kou += ans[pos];
                ++pos;
            }
            else{
                if(f == 0)  f = 1;
                else if(f == 2){
                  cout << "NO\n";
                    return 0;
                }
            }
        }
        else{
            if(f == 2){
                                  cout << "NO\n";
                    return 0;
            }

        }
    if(pos == ans.length())cout << "YES\n";
    else    cout << "NO\n";
}