Problem:
Score : 100 points

Problem Statement

A Hitachi string is a concatenation of one or more copies of the string hi.

For example, hi and hihi are Hitachi strings, while ha and hii are not.

Given a string S, determine whether S is a Hitachi string.

Constraints

The length of S is between 1 and 10 (inclusive).

S is a string consisting of lowercase English letters.

Input

Input is given from Standard Input in the following format:

S

Output

If S is a Hitachi string, print Yes; otherwise, print No.

Sample Input 1

hihi

Sample Output 1

Yes

hihi is the concatenation of two copies of hi, so it is a Hitachi string.

Sample Input 2

hi

Sample Output 2

Yes

Sample Input 3

ha

Sample Output 3

No

Solution in C++14 (GCC 5.4.1) (judge verdict: Accepted)

#include <bits/stdc++.h>
typedef long long ll;
#define rep(i,n) for(ll i=0;i<(n);i++)
#define repr(i,n) for(ll i=(n-1);i>=0;i--)
#define pb push_back
#define mp make_pair
#define all(x) x.begin(),x.end()
#define br cout << endl;
using namespace std;
const int INF = 1e9;
const int MOD = 1e9+7;
using Graph = vector<vector<ll>>;
template<class T> inline bool chmin(T &a, T b) { if(a > b){ a = b; return true;} return false;}
template<class T> inline bool chmax(T &a, T b) { if(a < b){ a = b; return true;} return false;}

// 0 false, 1 true 
// string to int : -48
// ceil(a)  1.2->2.0
// c++17	g++ -std=c++17 a.cpp

int main() {
    string s;
    cin >> s;

    if(s == "hi" || s =="hihi" || s == "hihihi" || s == "hihihihi" || s == "hihihihihi"){
        cout << "Yes" << endl;
    }else{
        cout << "No" << endl;
    }

    /*
    if(s.size() == 1){
        cout << "No" << endl;
        return 0;
    }

    string ans = "Yes";
    rep(i, s.size()){
        if(i % 2 == 0){
            if(s.at(i) == 'h'){
                continue;
            }else{
                ans = "No";

            }
        }else{
            if(s.at(i) == 'i'){
                continue;
            }else{
                ans = "No";
            }
        }
    }
    cout << ans << endl;
    return 0;
    */

}