#include <bits/stdc++.h>
#include <boost/range/irange.hpp>

using namespace std;
using namespace boost;

main() {
    const auto* p = "keyence";

    string s;
    cin >> s;
    int state = 0;
    for (auto c : s) {
        if (c == *p) {
            ++p;
            if (state == 1) {
                state = 2;
            }
        } else {
            if (state == 2) {
                cout << "NO" << endl;
                return 0;
            }
            state = 1;
        }
    }

    cout << (*p == 0 ? "YES" : "NO") << endl;
}