跳到主要内容
图灵 OJTURING / ONLINE JUDGE

#F0783. Fake News (easy)

  • ID: 789
  • 传统题
  • 2000ms
  • 256MiB
  • 尝试: 0
  • AC · 已通过: 0
  • 教学难度:待分级
  • 上传者:
  • 待分类
  • 整理状态
  • 难度待定
  • 难度
  • 共享题库
  • Codeforces
  • 英文题面
  • 题目来源
  • 题面语言

Fake News (easy)

题目描述

G. Fake News (easy)
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

As it's the first of April, Heidi is suspecting that the news she reads today are fake, and she does not want to look silly in front of all the contestants. She knows that a newspiece is fake if it contains heidi as a subsequence. Help Heidi assess whether the given piece is true, but please be discreet about it...

Input

The first and only line of input contains a single nonempty string s of length at most 1000 composed of lowercase letters (a-z).

Output

Output YES if the string s contains heidi as a subsequence and NO otherwise.

Examples
Input
abcheaibcdi
Output
YES
Input
hiedi
Output
NO
Note

A string s contains another string p as a subsequence if it is possible to delete some characters from s and obtain p.


题目来源:fps-www.educg.net-codeforce-1-2833.xml.zip;FPS 共享题包,题包内第 210 题。保留原作者与原赛事署名。