import sys
import re
for line in sys.stdin:
str = re.match(r'^N(IE|O).*[EO]{5,}.*!!!.*', line.replace("\n", ""), flags=re.IGNORECASE)
if str:
print('yes')
else:
print("no")