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



Sample input:
hihi


Sample output:
Yes

Submission status: Wrong Answer

Solution code:
large_s = input()

con = 0
str_check = ""
for i in range(len(large_s)):
    z = large_s.find('hi', con, len(large_s))
    if (0 <= z):
        print(z)
        str_check += str(z)
        con += 2

if (str_check=='0' or str_check=='02' or str_check=='024' or str_check=='0246' or str_check=='02468'):
    print("YES")

Submission status: Wrong Answer

Solution code:
S=str(input())
if S.count('hi')>=1:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
li = list(input())
n = len(li)
for i in range(0, int(n / 2), 2):
    if li[i] == 'h' and li[i + 1] == 'i' and n % 2 == 0:
        pass
    else:
        print('No')
        exit()
print('Yes')

Submission status: Wrong Answer

Solution code:
li = list(input())
n = len(li)
for i in range(0, int(n / 2), 2):
    if li[i] == 'h' and li[i + 1] == 'i':
        pass
    else:
        print('No')
        exit()
print('Yes')

Submission status: Wrong Answer

Solution code:
li = input().split()
n = len(li)
for i in range(int(n / 2)):
  if li[n] == 'h' and li[n + 1] == 'i':
    pass
  else:
    print('No')
    exit()
print('Yes')

Submission status: Wrong Answer

Solution code:
# coding: utf-8
import re
import math
import itertools
from copy import deepcopy
import fractions
import random
from heapq import heappop,heappush
import time
import os
import sys
import datetime
from functools import lru_cache
readline=sys.stdin.readline
sys.setrecursionlimit(2000)
#import numpy as np
alphabet="abcdefghijklmnopqrstuvwxyz"
mod=int(10**9+7)
inf=int(10**20)
def yn(b):
    if b:
        print("yes")
    else:
        print("no")
def Yn(b):
    if b:
        print("Yes")
    else:
        print("No")
def YN(b):
    if b:
        print("YES")
    else:
        print("NO")
class union_find():
    def __init__(self,n):
        self.n=n
        self.P=[a for a in range(N)]
        self.rank=[0]*n
 
    def find(self,x):
        if(x!=self.P[x]):self.P[x]=self.find(self.P[x])
        return self.P[x]
 
    def same(self,x,y):
        return self.find(x)==self.find(y)
 
    def link(self,x,y):
        if self.rank[x]<self.rank[y]:
            self.P[x]=y
        elif self.rank[y]<self.rank[x]:
            self.P[y]=x
        else:
            self.P[x]=y
            self.rank[y]+=1
 
    def unite(self,x,y):
        self.link(self.find(x),self.find(y))
 
    def size(self):
        S=set()
        for a in range(self.n):
            S.add(self.find(a))
        return len(S)
def bin_(num,size):
    A=[0]*size
    for a in range(size):
        if (num>>(size-a-1))&1==1:
            A[a]=1
        else:
            A[a]=0
    return A
def fac_list(n,mod_=0):
    A=[1]*(n+1)
    for a in range(2,len(A)):
        A[a]=A[a-1]*a
        if(mod>0):A[a]%=mod_
    return A
def comb(n,r,mod,fac):
    if(n-r<0):return 0
    return (fac[n]*pow(fac[n-r],mod-2,mod)*pow(fac[r],mod-2,mod))%mod
def next_comb(num,size):
    x=num&(-num)
    y=num+x
    z=num&(~y)
    z//=x
    z=z>>1
    num=(y|z)
    if(num>=(1<<size)):return False
    else:
        return num
def get_primes(n,type="int"):
    A=[True]*(n+1)
    A[0]=False
    A[1]=False
    for a in range(2,n+1):
        if A[a]:
            for b in range(a*2,n+1,a):
                A[b]=False
    if(type=="bool"):return A
    B=[]
    for a in range(n+1):
        if(A[a]):B.append(a)
    return B
def is_prime(num):
    if(num<=2):return False
    i=2
    while i*i<=num:
       if(num%i==0):return False
       i+=1
    return True
def join(A,c=" "):
    n=len(A)
    A=list(map(str,A))
    s=""
    for a in range(n):
        s+=A[a]
        if(a<n-1):s+=c
    return s
#############################################
s=input()
ans="Yes"
for a in range(0,(len(s)//2)*2,2):
  if not s[a:a+2]=="hi":
  	ans="No"
print(ans)

Submission status: Wrong Answer

Solution code:
s=input()
ans="Yes"
for a in range((len(s)//2)*2,2):
  if not s[a:a+2]=="hi":
  	ans="No"
print(ans)

Submission status: Wrong Answer

Solution code:
s=input()
if s.count("hi")>=1:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
''' ===========================================
from collections import deque
    appendleft() = push_front(), append = push_back()
    popfleft() = pop_front(), pop() = pop_back()
import heapq #heappush(trgt, val) heappop(trgt) trgt[0] __lt__<
=========================================== '''
##======================================python3
import sys
import collections
from sys import stdin #read(), readline()
sys.setrecursionlimit(10**6)
INF = 1<<50
MINI = 100005

class gv:
    input = None;
    
def build():
    gv.str = stdin.readline()

def solve():
    slen = len(gv.str)
    if (slen&1) == 1:
        print("No")
        return
    
    for i in range(0,slen,2):
        if (gv.str[i:i+2] == "hi") :
            pass
        else :
            print("No")
            return
    
    print("Yes")
    
    

if __name__ == '__main__':
    build()
    solve()

Submission status: Wrong Answer

Solution code:
''' ===========================================
from collections import deque
    appendleft() = push_front(), append = push_back()
    popfleft() = pop_front(), pop() = pop_back()
import heapq #heappush(trgt, val) heappop(trgt) trgt[0] __lt__<
=========================================== '''
##======================================python3
import sys
import collections
from sys import stdin #read(), readline()
input = stdin.readline
sys.setrecursionlimit(10**6)
INF = 1<<50
MINI = 100005

class gv:
    input = None;
    
def build():
    gv.str = input()

def solve():
    slen = len(gv.str)
    if (slen&1) == 1:
        print("No")
        return
    
    for i in range(0,slen,2):
        if (gv.str[i:i+2] == "hi") :
            pass
        else :
            print("No")
            return
    
    print("Yes")
    
    

if __name__ == '__main__':
    build()
    solve()

Submission status: Wrong Answer

Solution code:
''' ===========================================
from collections import deque
    appendleft() = push_front(), append = push_back()
    popfleft() = pop_front(), pop() = pop_back()
import heapq #heappush(trgt, val) heappop(trgt) trgt[0] __lt__<
=========================================== '''
##======================================python3
import sys
import collections
from sys import stdin #read(), readline()
input = stdin.readline
sys.setrecursionlimit(10**6)
INF = 1<<50
MINI = 100005

class gv:
    input = None;
    
def build():
    gv.str = input()

def solve():
    slen = len(gv.str)
    if (slen&1) == 1:
        print("No")
        return
    
    for i in range(0,slen,2):
        if (gv.str[i:i+1] == "hi") :
            pass
        else :
            print("No")
            return
    
    print("Yes")
    
    

if __name__ == '__main__':
    build()
    solve()

Submission status: Wrong Answer

Solution code:
''' ===========================================
from collections import deque
    appendleft() = push_front(), append = push_back()
    popfleft() = pop_front(), pop() = pop_back()
import heapq #heappush(trgt, val) heappop(trgt) trgt[0] __lt__<
=========================================== '''
##======================================python3
import sys
import collections
from sys import stdin #read(), readline()
input = stdin.readline
sys.setrecursionlimit(10**6)
INF = 1<<50
MINI = 100005

class gv:
    input = None;
    
def build():
    gv.str = input()

def solve():
    slen = len(gv.str)
    if (slen&1) == 1:
        print("No")
        return
    
    for i in (0,slen,2):
        if (gv.str[i:i+1] == "hi") :
            pass
        else :
            print("No")
            return
    
    print("Yes")
    
    

if __name__ == '__main__':
    build()
    solve()

Submission status: Wrong Answer

Solution code:
import re

def judge(check_string):

    HITACH_STRING = "hi"

    # check length
    if not((1 <= len(check_string)) and (len(check_string) <= 10)):
        print("No")

    allow_pattern = "[a-z]+"
    group = re.match(allow_pattern, check_string)


    if HITACH_STRING in check_string:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    hitachi_string = input()
    judge(hitachi_string)

Submission status: Wrong Answer

Solution code:
def judge(check_string):

    HITACH_STRING = "hi"

    if not((1 <= len(check_string)) and (len(check_string) <= 10)):
        print("No")

    if HITACH_STRING in check_string:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    hitachi_string = input()
    judge(hitachi_string)

Submission status: Wrong Answer

Solution code:
def judge(check_string):
    HITACH_STRING = "hi"

    if HITACH_STRING in check_string:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    hitachi_string = input()
    judge(hitachi_string)

Submission status: Wrong Answer

Solution code:
s=input()
count=0

for i in range(len(s)-1):
  if s[i]=="h" and s[i+1]=="i":
    count+=1
    
if count>=1:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
S = input()
print("Yes" if "hi" in S else "No")

Submission status: Wrong Answer

Solution code:
if input().count("hi") >= 2:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
S = str(input())
 
S.replace("hi", "")
if S == "":
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
s = input()
ans = "No"

for i in range(5):
    if s == "hi" * i:
        ans = "Yes"

print(ans)

Submission status: Wrong Answer

Solution code:
s = input()

def check(s):
  if "hi" in s:
    return 'Yes'
  else:
    return 'No'

Submission status: Wrong Answer

Solution code:
s = str(input())
#print(s[0]+s[1])

hitati = "hi"

for i in range(5):
  if s == hitati:
    print("Yes")
    exit()
  else:
    hitati += hitati

print("No")

Submission status: Wrong Answer

Solution code:
s = str(input())
#print(s[0]+s[1])


if len(s)%2 !=0:
  print("No")
  exit()

for i in range(len(s)%2):
  if str(s[i]+s[i+1]) != "hi":
    print("No")
    break
  else:
    i+=1
print("Yes")

Submission status: Wrong Answer

Solution code:
s = str(input())
#print(s)
if len(s)%2 !=0:
  print("No")
  exit()
  
for i in range(len(s)%2):
  if str(s[i]+s[i+1]) != "hi":
    print("No")
    break
  else:
    i += 1
print("Yes")

Submission status: Wrong Answer

Solution code:
s = str(input())
#print(s)

for i in range(len(s)-1):
  if str(s[i]+s[i+1]) == "hi":
    print("Yes")
    break
  else:
    print("No")

Submission status: Wrong Answer

Solution code:
a = input()
if "hii" in a:
  print("No")
elif "hi" in a:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
word=input()
if 'hi' in word:
    if 'hii' in word:
        print('No')
    else:
        print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
word=input()
if 'hi' in word:
    if 'hii' in word:
        print('No')
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
S = input()
l = 1
newl = 0
while l > newl:
  l = len(S)
  newS = S.replace('hi','')
  newl = len(newS)
  S = newS
  
  
if len(S) == 0:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
S = input()
if 'hi' in S:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10000000)
from collections import defaultdict
from bisect import *
mod = 10**9+7

S = input()
for i in range(5):
    if 'hi' * (i+1) == S:
        print('Yes')
        exit()
print('No')

Submission status: Wrong Answer

Solution code:
s = list(input())

for i in range(len(s)):
    if i % 2 == 0:
        if s[i] == "h":
            continue
        else:
            print("No")
            exit()
    else:
        if s[i] == "i":
            continue
        else:
            print("No")
            exit()
else:
    print("Yes")

Submission status: Wrong Answer

Solution code:
s = list(input())
f = True
while len(s) > 1:
    h = s.pop(0)
    i = s.pop(0)
    if h == 'h' and i == 'i':
        continue
    else:
        print('No')
        f = False
        break
    if len(s) == 0:
        break
if f:
    print('Yes')

Submission status: Wrong Answer

Solution code:
s = input()
for i in range(len(s)):
  if i & 1 == 0:
    if s[i] != 'h':
      break
  else:
    if s[i] != 'i':
      break
else:
  print('Yes')
  exit()
print('No')

Submission status: Wrong Answer

Solution code:
S = list(input())

word_num = int(len(S)/2)

temp_num = 0

if len(S) % 2 == 0:
    for i in range(word_num):
        if S[2*i]+S[2*i+1] == 'hi':
            pass
        else:
            temp_num += 1
else:
    print('No')

if len(S) % 2 == 0 and temp_num == 0:
    print('Yes')
else:
    pass

Submission status: Wrong Answer

Solution code:
S = list(input())

word_num = int(len(S)/2)

temp_num = 0

if len(S) % 2 == 0:
    for i in range(word_num):
        if S[2*i]+S[2*i+1] == 'hi':
            pass
        else:
            temp_num += 1
else:
    print('No')

if temp_num == 0:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
S = list(input())

word_num = int(len(S)/2)

temp_num = 0

if len(S) % 2 == 0:
    for i in range(word_num):
        if S[2*i] == 'h':
            pass
        elif S[2*i+1] == 'i':
            pass
        else:
            temp_num += 1
else:
    print('No')

if temp_num == 0:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
S=input()
flag=True
if len(S)==1:
    print("No")
    exit()
for i in range(len(S)):
    if i%2==0:
        if S[i]!="h":
            flag=False
            break
    else:
        if S[i]!="i":
            flag=False
            break
if flag:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
S=input()
flag=True
for i in range(len(S)):
    if i%2==0:
        if S[i]!="h":
            flag=False
            break
    else:
        if S[i]!="i":
            flag=False
            break
if flag:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
S = input()
ans = S.count("hi")

if ans > 0:
        print("Yes")
else:
        print("No")

Submission status: Wrong Answer

Solution code:
s = input()
print("Yes")

Submission status: Wrong Answer

Solution code:
s = input()
if "hi" in s and "hii" not in s:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
s = input().split('i')

h = s[:len(s)-1]
space = s[len(s)-1]
ans = 'No'

for j in h:
  if j =='h' and space == '':
    ans = 'Yes'
  else:
    break
  
print(ans)

Submission status: Wrong Answer

Solution code:
s = input().split('i')

h = s[:len(s)-1]
space = s[len(s)-1]
ans = 'No'

for j in h:
  if j =='h' and space == '':
    ans = 'Yes'
  
print(ans)

Submission status: Wrong Answer

Solution code:
S=list(str(input()))
A=''
B=''
while len(S)>0:
    A+=S.pop()
    if len(S)>0:
        B+=S.pop()
if len(set(A))==len(set(B))==1:
    if 'h' in A or 'i' in A:
        if 'h' in B or 'i' in B:
            print('Yes')
        else:
            print('No')
    else:
        print('No')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
S=list(str(input()))
A=''
B=''
while len(S)>0:
    A+=S.pop()
    if len(S)>0:
        B+=S.pop()
if len(set(A))==len(set(B))==1:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
S=str(input())
if 'hi' in S:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
s = input()
sS = s.replace('hi', 'H', 50)
if 'H' in sS:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
s = input()
sS = s.replace('hi', 'H')
if 'H' in sS:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
s = input()
sS = s.replace('hi', 'H')
if 'H' in s:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
s = input()
sS = s.replace('hi', 'H')
slist = sorted(sS)
kaisu = slist.count('H')
if kaisu >= 1:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
S = input()
S_list = list(S)

count = 0
out = 0
for i in range(len(S_list)-1):
    #print(i)
    if S_list[i]=='h':
        if S_list[i+1]=='i':    
            if i+2 > len(S_list)-1:
                count += 1                
            else:
                if S_list[i+2]=='i':
                    out += 1

if count >0 and out ==0:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
import re
s = input()
#^(?=.*abc)(?!.*def).*$
repatter = re.compile("^(?=.*hi)(?!.*hii).*$")
result = repatter.match(s)
if result != None:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
S=input()
if S.find('hi')!=-1:
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
s = input()
if s.find("hi") != -1:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
S=input()
print("Yes" if "hi" in S else "No")

Submission status: Wrong Answer

Solution code:
S=input()
if S.count("hi")>=1:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
h=list(input())


a=[i for i,x in enumerate(h) if x=="h"]
b=0

for j in a:
    if j+3<=len(h):
        if h[j+1]=="i" and h[j+2]!="i":
            b+=1
        continue
        
    elif len(h)>=2:
        if  "h" in  h[-2] and "i" in  h[-1]:
            b+=1
        continue
    else:
        continue
if b>0:
    print("Yes")
    
else:
    print("No")

Submission status: Wrong Answer

Solution code:
h=list(input())


a=[i for i,x in enumerate(h) if x=="h"]
b=0

for j in a:
    if j+3<=len(h):
        if h[j+1]=="i" and h[j+2]!="i":
            b+=1
        continue
        
    elif len(h)>2:
        if  "h" in  h[-2] and "i" in  h[-1]:
            b+=1
        continue
    else:
        continue
if b>0:
    print("Yes")
    
else:
    print("No")

Submission status: Wrong Answer

Solution code:
h=list(input())


a=[i for i,x in enumerate(h) if x=="h"]
b=0

for j in a:
    if j+3<=len(h):
        if h[j+1]=="i" and h[j+2]!="i":
            b+=1
        continue
        
    else:
        if  "h" in  h[-2] and "i" in  h[-1]:
            b+=1
        continue
if b>0:
    print("Yes")
    
else:
    print("No")

Submission status: Wrong Answer

Solution code:
h=input()
h=list("hiipphii")

a=[i for i,x in enumerate(h) if x=="h"]
b=0

for j in a:
    if j+3<=len(h):
        if h[j+1]=="i" and h[j+2]!="i":
            b+=1
        continue
        
    else:
        if  "h" in  h[-2] and "i" in  h[-1]:
            b+=1
        continue
if b>0:
    print("Yes")
    
else:
    print("No")

Submission status: Wrong Answer

Solution code:
def solve():
  s = input()
  if "hi" in s:
    print("Yes")
  else:
    print("No")
solve()

Submission status: Wrong Answer

Solution code:
S = input()
flag = 0
for i in range(len(S)):
	if i%2 == 0 and S[i] != 'h':
		flag = 1
	if i%2 == 1 and S[i] != 'i':
		flag = 1
if flag == 0 or len(S)%2 == 1:
	print('No')
else:
	print('Yes')

Submission status: Wrong Answer

Solution code:
S = input()
flag = 0
for i in range(len(S)):
	if i%2 == 0 and S[i] != 'i':
		flag = 1
	if i%2 == 1 and S[i] != 'h':
		flag = 1
if flag == 0:
	print('No')
else:
	print('Yes')

Submission status: Wrong Answer

Solution code:
S = input()
flag = 0
for i in range(len(S)):
	if i == 0:
		continue
	if S[i-1] == 'h' and S[i] == 'i':
		flag = 1
if flag == 0:
	print('No')
else:
	print('Yes')

Submission status: Wrong Answer

Solution code:
import re
a=input()
c=re.findall('hi',a)
c=set(c)
if c=={"hi"}:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
import re
a=input()
c=re.findall('hi',a)
c=set(c)
if len(c)==1:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
s = input()
print('Yes' if set(s[::2]) == {'h'} and set(s[1::2]) == {'i'} else 'No')

Submission status: Wrong Answer

Solution code:
user = input()
container = [char for char in user]
if (container[0] == 'h' and container[1] == 'i'):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
S = input() 
if S == 'hi' or S == 'hihi' or S == 'hihihihi' or S == 'hihihihihi':
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
S = input() 
if S == 'hi' or S =='hihi' or S =='hihihihi' or S =='hihihihihi':
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
S = input() 
if 'hi' or 'hihi' or 'hihihihi' or 'hihihihihi':
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
S = input() 
if 'hi' or 'hihi':
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
S = input() 
if 'hi':
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
import sys

s=str(input())

for i in range(len(s)-1):
  if s[i]=="h" and s[i+1]=="i":
    print("Yes")
    sys.exit()
print("No")

Submission status: Wrong Answer

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-


def main():
    s = input().strip()
    ans = s.find("hi") >= 0
    print("Yes" if ans else "No")


if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
s=input()
for i in range(len(s)-1):
	if s[i]=="h" and s[i+1]=="i":
		print("Yes")
		exit()
print("No")

Submission status: Wrong Answer

Solution code:

s = input()

if len(s) // 2 ==1:
	print('No')
	exit()

if s == "hi"* (len(s) // 2):
	print('Yes')
else:
	print('No')

Submission status: Wrong Answer

Solution code:
s = input()

if len(s) // 2 ==1:
	print('Np')
	exit()

if s == "hi"* (len(s) // 2):
	print('Yes')
else:
	print('No')

Submission status: Wrong Answer

Solution code:
s = input()
hitaStr =''
i = 0
if len(s)  <=10:
	while i < len(s):
		if s[i] not in"hitac":
			break
		hitaStr += s[i]
		if len(hitaStr) ==1 and hitaStr in "aiueo":
			hitaStr =''
			break
		if hitaStr not in 'hitachi':
			hitaStr = ''
		else:
			i += 1
if hitaStr:
	print('Yes')
else:
	print('No')

Submission status: Wrong Answer

Solution code:
s = input()
hitaStr =''
i = 0
while i < len(s):
	if s[i] not in"hitac":
		break
	hitaStr += s[i]
	if len(hitaStr) ==1 and hitaStr in "aiueo":
		hitaStr =''
		break
	if hitaStr not in 'hitachi':
		hitaStr = ''
	else:
		i += 1
if hitaStr:
	print('Yes')
else:
	print('No')

Submission status: Wrong Answer

Solution code:
s = input()
hitaStr =''
i = 0
while i < len(s):
	hitaStr += s[i]
	if len(hitaStr) ==1 and hitaStr in "aiueo":
		hitaStr =''
		break
	if hitaStr not in 'hitachi':
		hitaStr = ''
	else:
		i += 1
if hitaStr:
	print('Yes')
else:
	print('No')

Submission status: Wrong Answer

Solution code:

S = str(input())


if __name__ == "__main__":
    h_pointer = False
    i_pointer = False
    check = True

    if(len(S)%2 != 0):
        print('No') 

    for i in range(0, len(S) ):
        if(h_pointer and i_pointer == False and S[i] == "i"):
            h_pointer = False

        elif(h_pointer == False and i_pointer == False and S[i] == "h"):
            h_pointer = True
        else:
            print('No')
            check = False
            break
        
        # print(h_pointer, i_pointer, check)


    if check: 
        print('Yes')

Submission status: Wrong Answer

Solution code:

S = str(input())


if __name__ == "__main__":
    h_pointer = False
    i_pointer = False
    check = True

    for i in range(0, len(S) ):
        if(h_pointer and i_pointer == False and S[i] == "i"):
            h_pointer = False

        elif(h_pointer == False and i_pointer == False and S[i] == "h"):
            h_pointer = True
        else:
            print('No')
            check = False
            break
        
        # print(h_pointer, i_pointer, check)


    if check: 
        print('Yes')

Submission status: Wrong Answer

Solution code:
h=input()
 
if "hi" in h and "hii" not in h:
  
  print("Yes")
elif 'hi' in h[-2:]:
  print('Yes')
else:
  print("No")

Submission status: Wrong Answer

Solution code:
S = str(input("Word: ")).lower()
if S == "hi" * int(len(S) / 2) and 1 <= len(S) <= 10:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
word = str(input("Enter something: ")).lower()
if word == "hi" * int(len(word) / 2) and 1 <= len(word) <= 10:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
hitatistr = input()
count = 0
flag = "ok"
for i in hitatistr:
  if count % 2 == 0:
    if i != "h":
      flag = "ng"
      break
  else:
    if i != "i":
      flag = "ng"
  count = count + 1
if flag == "ok" and count >= 2 and count % 2 == 1:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
hitatistr = input()
count = 0
flag = "ok"
for i in hitatistr:
  if count % 2 == 0:
    if i != "h":
      flag = "ng"
      break
  else:
    if i != "i":
      flag = "ng"
  count = count + 1
if flag == "ok" and count >= 2:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
hitatistr = input()
count = 0
flag = "ok"
for i in hitatistr:
  if count % 2 == 0:
    if i != "h":
      flag = "ng"
      break
  else:
    if i != "i":
      flag = "ng"
  count = count + 1
if flag == "ok":
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
import re

S=input()

pattern = '(hi)+'

result = re.match(pattern, S)

if result:
	print('Yes')
else:
	print('No')

Submission status: Wrong Answer

Solution code:
s=input()
for i in range(len(s)):
  if i == len(s)-1:
    print('No')
    break
  if s[i]=='h':
    if s[i+1]=='i':
      print('Yes')
      break

Submission status: Wrong Answer

Solution code:
s = input()
s.replace("hi", "")
print("Yes" if s=="" else "No")

Submission status: Wrong Answer

Solution code:
S = input()


flg = True

for i in range(len(S)):
    if flg == True and S[i] == "h":
        flg = False
        continue
    elif flg == False and S[i] == "i":
        flg = True
        continue
    else:
        print("No")
        break
else:
    if S == "":
        print("No")
    else:
        print("Yes")

Submission status: Wrong Answer

Solution code:
while True:
    s = input()
    if 1 <= len(s) <= 10:
        break

flag = False

for l in range(len(s)):
    if s[len(s)-2]=="h" and s[len(s)-1]=="i":
        print("Yes")
        flag = True
        break
    
    if s[l]=="h" and s[l+1]=="i" and s[l+2]!="i":
        print("Yes")
        flag = True
        break
        
    
if flag == False:
    print("No")

Submission status: Wrong Answer

Solution code:
while True:
    s = input()
    if 1 <= len(s) <= 10:
        break

flag = False

for l in range(len(s)):
    print(s[len(s)-2] + s[len(s)-1])
    if s[len(s)-2]=="h" and s[len(s)-1]=="i":
        print("Yes")
        flag = True
        break
    
    if s[l]=="h" and s[l+1]=="i" and s[l+2]!="i":
        print("Yes")
        flag = True
        break
        
    
if flag == False:
    print("No")

Submission status: Wrong Answer

Solution code:
while True:
    s = input()
    if 1 <= len(s) <= 10:
        break

flag = False
    
for l in range(len(s)-2):
    if s[len(s)-2]=="h" and s[len(s)-1]=="i":
        print("Yes")
        flag = True
        break
    if s[l]=="h" and s[l+1]=="i" and s[l+2]!="i":
        print("Yes")
        flag = True
        break
        
    
if flag == False:
    print("No")

Submission status: Wrong Answer

Solution code:
while True:
    s = input()
    if 1 <= len(s) <= 10:
        break

flag = False
for l in range(len(s)-2):
    if s[l]=="h" and s[l+1]=="i" and s[l+2]!="i":
        print("Yes")
        flag = True
        break
    
if flag == False:
    print("No")

Submission status: Wrong Answer

Solution code:
h = input()
if "hi" in h:
    print("No")
elif len(h.replace("hi","")) < len(h):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
h = input()
if len(h.replace("hi","")) < len(h):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
s=list(input())
f=1
for i in range(len(s)):
    if i%2 and s[i]!="i":
        f=0
    elif i%2==0 and s[i]!="h":
        f=0
print("Yes" if f else "No")

Submission status: Wrong Answer

Solution code:
s=list(input())
h=s.count("h")
i=s.count("i")
x=len(s)//2
if x==h and x==i and len(s)%2==0:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
s=list(input())
h=s.count("h")
i=s.count("i")
x=len(s)//2
if x==h and x==i:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
S=input()
A=S.count("h")
B=S.count("i")
if A==B and A+B==len(S):
	print("Yes")
else:
	print("No")

Submission status: Wrong Answer

Solution code:
text = input()

def checkHitachi(text):
  check_i = False
  for i in range(len(text)):
    if check_i:
      if (text[i] != 'i'):
        return 'No'
      else:
        check_i = False
    else:
      if (text[i] != 'h'):
        return 'No'
      else:
        check_i = True
  return 'Yes'


print(checkHitachi(text))

Submission status: Wrong Answer

Solution code:
tgt = str(input())
print(tgt.find("hi"))

if tgt.find("hi") > 0 and tgt.find("hii") <= 0 :
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
tgt = str(input())

if tgt.find("hi") > 0:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
tgt = str(input())

print("The source string:" ,tgt)
 
print(tgt.find("hi"))

if tgt.find("hi") > 0:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
tgt = str(input())

if 'hi' in tgt:
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
S = input()
for i in range(len(S)//2):
    if S[2*i:2*i+2] != 'hi':
        print('No')
        exit()
print('Yes')

Submission status: Wrong Answer

Solution code:
S = str(input())

if S == 'hi' or S == 'hihi' or S == 'hihihi' or S == 'hihihihi' or S == 'hihihihihihi':
    print ('Yes')
else:
    print ('No')

Submission status: Wrong Answer

Solution code:
S = input()
ans = "No"
for i in range(len(S)-1):
    if S[i]+S[i+1]=="hi":
        ans = "Yes"
print(ans)

Submission status: Wrong Answer

Solution code:
S = input()

if not S in 'hi':
  print('No')
else:
  print('Yes')

Submission status: Wrong Answer

Solution code:
S = input()

if S in 'hi':
  print('Yes')
else:
  print('No')

Submission status: Wrong Answer

Solution code:
l=input()
if "hi" in l:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
s = input()
print('Yes' if 'hi' in s else 'No')

Submission status: Wrong Answer

Solution code:
import re
S=input("")
S2=re.split("(..)",S)[1::2]
if S2.count("hi")==len(S2):
    print("Yes")
else:
    print("No")