unittest
{
	assert( [ "keyofscience" ].parse.expand.solve == "YES" );
	assert( [ "mpyszsbznf" ].parse.expand.solve == "NO" );
	assert( [ "ashlfyha" ].parse.expand.solve == "NO" );
	assert( [ "keyence" ].parse.expand.solve == "YES" );
}



import std.conv;
import std.range;
import std.stdio;
import std.string;
import std.typecons;

void main()
{
	stdin.byLineCopy.parse.expand.solve.writeln;
}

auto parse( Range )( Range input )
if( isInputRange!Range && is( ElementType!Range == string ) )
{
	auto s = input.front;
	return tuple( s );
}

auto solve( string s )
{
	const KEYENCE = "keyence";
	
	auto del = false;
	auto ki = 0L;
	auto dc = 0L;
	
	foreach( c; s )
	{
		if( ki < KEYENCE.length && c == KEYENCE[ ki ] )
		{
			ki++;
			del = false;
		}
		else
		{
			if( !del ) dc++;
			del = true;
		}
	}
	
	return ( ki == KEYENCE.length && dc <= 1 ) ? "YES" : "NO";
}
