def my_index(l, x, default=False):
    if x in l:
        return l.index(x)
    else:
        return -1

a = input().split("!!!")
a = list(a[0])
judge = 0
count = 0 
tmp1 = 0 
tmp2 = 0
A = []
B = []

A.append(my_index(a, 'k'))
tmp1 = my_index(a, 'k')
if (my_index(a, 'k') != -1):
 a[ my_index(a, 'k') ] = 'AAA'
 judge += 1

A.append(my_index(a, 'e'))
tmp2 = my_index(a, 'e')
if (my_index(a, 'e') != -1):
 a[ my_index(a, 'e') ] = 'AAA'
 judge += 1
if (tmp2 - tmp1 >= 2 ):
 count +=1
tmp1 = tmp2

A.append(my_index(a, 'y'))
tmp2 = my_index(a, 'y')
if (my_index(a, 'y') != -1):
 a[ my_index(a, 'y') ] = 'AAA'
 judge += 1
if (tmp2 - tmp1 >= 2 ):
 count +=1
tmp1 = tmp2

A.append(my_index(a, 'e'))
tmp2 = my_index(a, 'e')
if (my_index(a, 'e') != -1):
 a[ my_index(a, 'e') ] = 'AAA'
 judge += 1
if (tmp2 - tmp1 >= 2 ):
 count +=1
tmp1 = tmp2

A.append(my_index(a, 'n'))
tmp2 = my_index(a, 'n')
if (my_index(a, 'n') != -1):
 a[ my_index(a, 'n') ] = 'AAA'
 judge += 1
if (tmp2 - tmp1 >= 2 ):
 count +=1
tmp1 = tmp2

A.append(my_index(a, 'c'))
tmp2 = my_index(a, 'c')
if (my_index(a, 'c') != -1):
 a[ my_index(a, 'c') ] = 'AAA'
 judge += 1
if (tmp2 - tmp1 >= 2 ):
 count +=1
tmp1 = tmp2

A.append(my_index(a, 'e'))
tmp2 = my_index(a, 'e')
if (my_index(a, 'e') != -1):
 a[ my_index(a, 'e') ] = 'AAA'
 judge += 1
if (tmp2 - tmp1 >= 2 ):
 count +=1
tmp1 = tmp2

B = A
A.sort()
if( (A == B) and (judge==7) and (count<=2) ):
 print('YES')
else:
 print("NO")