#include<iostream>
#include<algorithm>
using namespace std;
int main() {
	char s[1020];
	char c[] = "keyence";
	cin >> s;
	int j = 0, k = 0;

	for (j = 0; s[j] != '\0'; j++);

	int i;
	for (i = 0;i<7; i++) {
		if (s[i] != c[i])break;
	}
	
	for (k = 0; k < 7; k++) {
		if (s[j-k-1] != c[7-k-1])break;
	}
	if (i == 7||k==7||i+k>=7)cout << "YES";
	else cout << "NO";

}
