buggy_code stringlengths 11 625k | fixed_code stringlengths 17 625k | bug_type stringlengths 2 4.45k | language int64 0 8 | token_count int64 5 200k |
|---|---|---|---|---|
a=input()
flg=0
for i in range(len(a)//2):
if not a[2*i]=='h' and a[2*i+1]=='i':
flg=1
if len(a)%2!=0 or flg==1:
print("No")
else:
print("Yes") | a=input()
flg=0
for i in range(len(a)//2):
if not (a[2*i]=='h' and a[2*i+1]=='i'):
flg=1
if len(a)%2!=0 or flg==1:
print("No")
else:
print("Yes") | [["+", 8, 196, 0, 57, 15, 681, 28, 23, 0, 24], ["+", 8, 196, 0, 57, 15, 681, 28, 23, 0, 25]] | 5 | 78 |
#include <iostream>
#include <string>
using namespace std;
int main() {
int i;
string s;
cin >> s;
if (s.size() == 1) {
cout << "No" << endl;
return 0;
}
for (i = 0; i < s.size(); i++) {
if (i & 1) {
if (s[i] != 'i') {
cout << "No" << endl;
return 0;
}
} else {
... | #include <iostream>
#include <string>
using namespace std;
int main() {
int i;
string s;
cin >> s;
if (s.size() & 1) {
cout << "No" << endl;
return 0;
}
for (i = 0; i < s.size(); i++) {
if (i & 1) {
if (s[i] != 'i') {
cout << "No" << endl;
return 0;
}
} else {
... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 67]] | 1 | 133 |
S = input()
N = int(len(S)/2)
[print('Yes') if S == 'hi'*N else print('NO')] | S = input()
N = int(len(S)/2)
[print('Yes') if S == 'hi'*N else print('No')] | [["-", 0, 41, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 41, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 39 |
#include <bits/stdc++.h>
using namespace std;
#define INP "solve"
#define OUT "solve"
const int QQ = 3e5 + 10;
const int maxN = (1 << 21) + 100;
const int maxM = 3e5 + 100;
const long long oo = 4e18;
const int INF = 2e9 + 100;
const int MOD = 1e9 + 7;
const int Base = 311;
const long double du = 1e-9;
const string Y... | #include <bits/stdc++.h>
using namespace std;
#define INP "solve"
#define OUT "solve"
const int QQ = 3e5 + 10;
const int maxN = (1 << 21) + 100;
const int maxM = 3e5 + 100;
const long long oo = 4e18;
const int INF = 2e9 + 100;
const int MOD = 1e9 + 7;
const int Base = 311;
const long double du = 1e-9;
const string Y... | [["-", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["+", 0, 57, 64, 1, 0, 16, 12, 5, 0, 6], ["-", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 75, 76, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 294 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
using ll = long long;
using ull = unsigned long long;
using vv = vector<vector<int>>;
using P = pair<int, int>;
int main() {
string s;
cin >> s;
if (s.size() % 2 != 0)
cout << "No" << endl;
return 0;
for (i... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
using ll = long long;
using ull = unsigned long long;
using vv = vector<vector<int>>;
using P = pair<int, int>;
int main() {
string s;
cin >> s;
if (s.size() % 2 != 0) {
cout << "No" << endl;
return 0;
}
... | [["+", 0, 14, 8, 9, 0, 57, 64, 9, 0, 45], ["+", 0, 14, 8, 9, 0, 57, 64, 9, 0, 46]] | 1 | 164 |
import java.io.*;
import java.util.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String tests = br.readLine();
if (tests.length() %... | import java.io.*;
import java.util.*;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
String tests = br.readLine();
if (tests.length() %... | [["+", 49, 200, 51, 492, 3, 4, 0, 16, 31, 22], ["+", 49, 200, 51, 492, 3, 4, 0, 16, 17, 72], ["+", 8, 196, 0, 57, 75, 196, 0, 57, 0, 95], ["+", 0, 57, 75, 196, 0, 57, 75, 196, 0, 45], ["+", 0, 57, 75, 196, 0, 57, 75, 196, 0, 46]] | 3 | 190 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int N = S.size();
string ans = "No";
int cnt = 0;
for (int i = 0; i < N - 1; i++) {
if (S[i] == 'h' && S[i + 1] == 'i') {
cnt++;
i++;
}
}
if (cnt * 2 && N)
ans = "Yes";
cout << ans << endl;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int N = S.size();
string ans = "No";
int cnt = 0;
for (int i = 0; i < N - 1; i++) {
if (S[i] == 'h' && S[i + 1] == 'i') {
cnt++;
i++;
}
}
if (N && cnt * 2 == N)
ans = "Yes";
cout << ans << endl;
}... | [["+", 8, 9, 0, 57, 15, 339, 51, 16, 31, 22], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 98], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 60]] | 1 | 108 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
int cnt = 0, len = s.length();
// cout<<len<<" ";
for (int i = 0; i < s.length(); i++)
if (s[i] == 'h' && s[i + 1] == 'i')
cnt++;
if (cnt == len / 2)
cout << "Yes\n";
else
cout << "No\n";
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
double cnt = 0, len = s.length();
// cout<<len<<" ";
for (int i = 0; i < s.length(); i++)
if (s[i] == 'h' && s[i + 1] == 'i')
cnt++, i++;
if (cnt == len / 2)
cout << "Yes\n";
else
cout << "No\n";
return 0;
}... | [["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 39, 40], ["+", 8, 57, 64, 1, 0, 34, 31, 27, 17, 29], ["+", 0, 7, 8, 57, 64, 1, 0, 34, 0, 21], ["+", 8, 57, 64, 1, 0, 34, 12, 27, 28, 22]] | 1 | 102 |
#!/usr/bin/env python3
def main():
S = input()
for i in range(1, 5):
h = 'hi' * i
if S == h:
print('Yes')
return
else:
print('No')
main()
| #!/usr/bin/env python3
def main():
S = input()
for i in range(1, 6):
h = 'hi' * i
if S == h:
print('Yes')
return
else:
print('No')
main()
| [["-", 8, 196, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 8, 196, 0, 7, 12, 652, 3, 4, 0, 612]] | 5 | 51 |
s = input()
if len(s) < 1 or len(s) >10:
ans = False
if len(s) >= 1 or len(s) <= 10:
if s == 'hi' or s == 'hihi' or s == 'hihihi' or s == 'hihihhihi' or s == 'hihihihihi':
ans =True
else:
ans =False
if ans:
print ('Yes')
else:
print('No') | s = input()
ans = False
if len(s) < 1 or len(s) >10:
ans = False
if len(s) >= 1 or len(s) <= 10:
if s == 'hi' or s == 'hihi' or s == 'hihihi' or s == 'hihihihi' or s == 'hihihihihi':
ans =True
else:
ans =False
if ans:
print ('Yes')
else:
print('No') | [["+", 36, 36, 0, 656, 0, 1, 0, 662, 31, 22], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 0, 32], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 12, 147], ["-", 15, 679, 31, 679, 12, 666, 0, 557, 0, 6], ["+", 15, 679, 31, 679, 12, 666, 0, 557, 0, 6]] | 5 | 94 |
s=str(inputs())
tmp = s.replace('hi','')
if tmp=='':
print('Yes')
else:
print('No') | s=str(input())
tmp = s.replace('hi','')
if tmp=='':
print('Yes')
else:
print('No')
| [["-", 0, 662, 12, 652, 3, 4, 0, 652, 63, 22], ["+", 0, 662, 12, 652, 3, 4, 0, 652, 63, 22]] | 5 | 41 |
import re
s = input()
isHitachi = re.search("^(hi)+$")
if isHitachi:
print("Yes")
else:
print("No") | import re
s = input()
isHitachi = re.search("^(hi)+$", s)
if isHitachi:
print("Yes")
else:
print("No") | [["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 21], ["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 22]] | 5 | 34 |
#include <algorithm>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#define INF 0x3f3f3f3f
#define LL long long
using namespace std;
char s[15];
int main() {
scanf("%s", s);
int flag = 1;
int len = strlen(s);
for (int i = 0; i < len - 1; i++) {
if (s[i] == 'h') {
... | #include <algorithm>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#define INF 0x3f3f3f3f
#define LL long long
using namespace std;
char s[15];
int main() {
scanf("%s", s);
int flag = 1;
int len = strlen(s);
for (int i = 0; i < len - 1; i++) {
if (s[i] == 'h') {
... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 154 |
#include <iostream>
#include <string>
using namespace std;
int main() {
string s = "";
cin >> s;
size_t size = s.length();
int h = size;
if (h % 2 == 1) {
cout << "NO" << endl;
} else {
int n = h / 2;
int suc = 0;
for (int i = 0; i < n; i++) {
string d = s.substr(i * 2, 2);
i... | #include <iostream>
#include <string>
using namespace std;
int main() {
string s = "";
cin >> s;
size_t size = s.length();
int h = size;
if (h % 2 == 1) {
cout << "No" << endl;
} else {
int n = h / 2;
int suc = 0;
for (int i = 0; i < n; i++) {
string d = s.substr(i * 2, 2);
i... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 154 |
#include <iostream>
using namespace std;
int main() {
string S;
cin >> S;
if (S == "hi") {
cout << "Yes" << endl;
} else if (S == "hihi") {
cout << "Yes" << endl;
} else if (S == "hihihi") {
cout << "Yes" << endl;
} else if (S == "hihihihi") {
cout << "Yes" << endl;
} else if (S == "hih... | #include <iostream>
using namespace std;
int main() {
string S;
cin >> S;
if (S == "hi") {
cout << "Yes" << endl;
} else if (S == "hihi") {
cout << "Yes" << endl;
} else if (S == "hihihi") {
cout << "Yes" << endl;
} else if (S == "hihihihi") {
cout << "Yes" << endl;
} else if (S == "hih... | [["-", 0, 57, 15, 339, 51, 16, 12, 5, 0, 6], ["+", 0, 57, 15, 339, 51, 16, 12, 5, 0, 6]] | 1 | 127 |
S = input()
if len(S) == 1:
print("No")
exit()
for i in range(len(S)):
if i % 2 == 1:
if S[i] != 'i':
print("No")
exit()
if i % 2 == 0:
if S[i] != 'h':
print("No")
exit()
print("Yes") | S = input()
if len(S) % 2 == 1:
print("No")
exit()
for i in range(len(S)):
if i % 2 == 1:
if S[i] != 'i':
print("No")
exit()
if i % 2 == 0:
if S[i] != 'h':
print("No")
exit()
print("Yes") | [["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 109], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 12, 612]] | 5 | 91 |
#N=int(input())
#N,M=map(int, input().split())
#L=list(map(int, input().split()))
S = str(input())
if len(S)==1:
print('No')
exit()
n = 0
while len(S) > n:
if n % 2 == 1 and S[n] != 'i':
print('No')
exit()
elif n % 2 == 0 and S[n] != 'h':
print('No')
exit()
n += 1
print(... | #N=int(input())
#N,M=map(int, input().split())
#L=list(map(int, input().split()))
S = str(input())
if len(S)%2==1:
print('No')
exit()
n = 0
while len(S) > n:
if n % 2 == 1 and S[n] != 'i':
print('No')
exit()
elif n % 2 == 0 and S[n] != 'h':
print('No')
exit()
n += 1
prin... | [["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 109], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 12, 612]] | 5 | 98 |
#include <iostream>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
if (s == "hi") {
printf("YES\n");
} else if (s == "hihi") {
printf("YES\n");
} else if (s == "hihihi") {
printf("YES\n");
} else if (s == "hihihihi") {
printf("YES\n");
} else if (s == "hihihihihi... | #include <iostream>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
if (s == "hi") {
printf("Yes\n");
} else if (s == "hihi") {
printf("Yes\n");
} else if (s == "hihihi") {
printf("Yes\n");
} else if (s == "hihihihi") {
printf("Yes\n");
} else if (s == "hihihihihi... | [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 1 | 129 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string str;
cin >> str;
int len = str.length();
int i = 0, flag = 0;
while (i < len) {
if (str[i] == 'h' && str[i + 1] == 'i')
i = i + 2;
else {
flag = 1;
break;
}
}
if (flag == 1)
cout << "NO" << endl;
els... | #include <bits/stdc++.h>
using namespace std;
int main() {
string str;
cin >> str;
int len = str.length();
int i = 0, flag = 0;
while (i < len) {
if (str[i] == 'h' && str[i + 1] == 'i')
i = i + 2;
else {
flag = 1;
break;
}
}
if (flag == 1)
cout << "No" << endl;
els... | [["-", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 64, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 108 |
s=input()
flg=0
if len(s)%2!=0:
print("No")
else:
for i in range(0,len(s)-1,2):
if s[i:i+2]!="hi":
flg +=1
break
continue
if flg==0:
print("Yes")
else:
print("No") | s=input()
flg=0
if len(s)%2!=0:
flg+=1
else:
for i in range(0,len(s)-1,2):
if s[i:i+2]!="hi":
flg +=1
break
continue
if flg==0:
print("Yes")
else:
print("No") | [["-", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655], ["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["+", 0, 57, 64, 196, 0, 1, 0, 677, 31, 22], ["+", 0, 57, 64,... | 5 | 81 |
require "pry-byebug"
S = gets.chomp.to_s.gsub!(/hi/, "")
if S == ""
puts "Yes"
else
puts "No"
end | S = gets.chomp.to_s.gsub!(/hi/, "")
if S == ""
puts "Yes"
else
puts "No"
end
| [["-", 36, 36, 36, 36, 0, 493, 0, 652, 735, 22], ["-", 0, 493, 0, 652, 3, 4, 0, 557, 0, 62], ["-", 0, 493, 0, 652, 3, 4, 0, 557, 0, 6]] | 4 | 36 |
const main =
(inputs) => {
const word = inputs[0];
var flag = true;
for (var i = 0; i < word.length; i++) {
var count = 0;
if (i % 2 === 0 && word[i] === 'h') {
count = count + 1;
}
if (i % 2 === 1 && word[i] === 'i') {
count = count + 1;
... | const main =
(inputs) => {
const word = inputs[0];
var flag = true;
for (var i = 0; i < word.length; i++) {
var count = 0;
if (i % 2 === 0 && word[i] === 'h') {
count = count + 1;
}
if (i % 2 === 1 && word[i] === 'i') {
count = count + 1;
... | [["-", 0, 57, 15, 23, 0, 16, 12, 16, 17, 47], ["-", 0, 57, 15, 23, 0, 16, 12, 16, 12, 555], ["+", 15, 23, 0, 16, 12, 16, 31, 16, 17, 109], ["+", 15, 23, 0, 16, 12, 16, 31, 16, 12, 555], ["+", 0, 57, 15, 23, 0, 16, 12, 16, 17, 565], ["+", 0, 57, 15, 23, 0, 16, 12, 16, 12, 555]] | 2 | 174 |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> LL;
int main(void) {
string S;
cin >> S;
int h = 0;
bool res = false;
for (int i = 0; i < S.size(); i++) {
if (h == 0 && S[i] == 'h') {
h++;
continue;
}
if (h == 1 && S[i] == 'i') {
h--;
... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<ll, ll> LL;
int main(void) {
string S;
cin >> S;
int h = 0;
bool res = false;
for (int i = 0; i < S.size(); i++) {
if (h == 0 && S[i] == 'h') {
h++;
res = false;
continue;
}
if (h == 1 && S[i] == '... | [["+", 0, 57, 64, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 57, 64, 9, 0, 1, 0, 11, 17, 32], ["+", 0, 57, 64, 9, 0, 1, 0, 11, 12, 147], ["+", 8, 9, 0, 57, 64, 9, 0, 1, 0, 35]] | 1 | 143 |
str = input()
yes = True
if len(str) < 2:
yes = False
for i in range(len(str)):
if (i % 2 == 0 and str[i] != 'h') or (i % 2 == 1 and str[i] != 'i'):
yes = False
break
print("Yes" if yes else "No")
| str = input()
yes = True
if len(str) % 2 == 1:
yes = False
for i in range(len(str)):
if (i % 2 == 0 and str[i] != 'h') or (i % 2 == 1 and str[i] != 'i'):
yes = False
break
print("Yes" if yes else "No")
| [["-", 36, 36, 0, 656, 0, 57, 15, 666, 667, 18], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 109], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 667, 60], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 0, 612]] | 5 | 81 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String total = scanner.nextLine();
if (total.length() == 1) {
System.out.println("No");
return;
}
for (int i = 0; i < total.length(); i++) {
if (i %... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String total = scanner.nextLine();
if (total.length() % 2 != 0) {
System.out.println("No");
return;
}
for (int i = 0; i < total.length(); i++) {
if ... | [["-", 8, 196, 0, 57, 15, 15, 0, 16, 17, 60], ["-", 8, 196, 0, 57, 15, 15, 0, 16, 12, 499], ["+", 0, 57, 15, 15, 0, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 15, 0, 16, 31, 16, 12, 499], ["+", 8, 196, 0, 57, 15, 15, 0, 16, 17, 79], ["+", 8, 196, 0, 57, 15, 15, 0, 16, 12, 499]] | 3 | 185 |
S = input()
if len(S) == 1:
print("No")
else:
while (len(S) != 0):
if S[0] == 'h' and S[1] == 'i':
S = S[2:]
else:
break
if len(S) != 0:
print("No")
else:
print("Yes") | S = input()
if len(S) % 2 == 1:
print("No")
else:
while (len(S) != 0):
if S[0] == 'h' and S[1] == 'i':
S = S[2:]
else:
break
if len(S) != 0:
print("No")
else:
print("Yes") | [["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 109], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 12, 612]] | 5 | 82 |
a = input()
l = list(a)
num = len(l)
TorF = True
if num % 2 == 0:
b = int(num/2)
for i in range(b):
if not a[2*i] == 'h' and a[2*i + 1] == 'i':
TorF = False
break
else:
TorF = False
if TorF == True:
print('Yes')
else:
print('No') | a = input()
l = list(a)
num = len(l)
TorF = True
if num % 2 == 0:
b = int(num/2)
for i in range(b):
if not (a[2*i] == 'h' and a[2*i + 1] == 'i'):
TorF = False
break
else:
TorF = False
if TorF == True:
print('Yes')
else:
print('No') | [["+", 8, 196, 0, 57, 15, 681, 28, 23, 0, 24], ["+", 8, 196, 0, 57, 15, 681, 28, 23, 0, 25]] | 5 | 97 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string a;
cin >> a;
int flag = 0;
if (a.length() == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < a.length(); i++) {
if (i % 2 == 0 && a[i] == 'h') {
continue;
}
if (i % 2 == 1 && a[i] == 'i') {
continue... | #include <bits/stdc++.h>
using namespace std;
int main() {
string a;
cin >> a;
int flag = 0;
if (a.length() % 2 == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < a.length(); i++) {
if (i % 2 == 0 && a[i] == 'h') {
continue;
}
if (i % 2 == 1 && a[i] == 'i') {
cont... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 134 |
#include <stdio.h>
int main() {
char S[10];
scanf("%s", S);
for (int i = 0; i < 8; i = i + 2) {
if ((S[i] == 'h') && (S[i + 1] == 'i')) {
if (S[i + 2] == ' ') {
break;
}
continue;
}
printf("No\n");
return 0;
}
printf("Yes\n");
return 0;
} | #include <stdio.h>
int main() {
char S[10];
scanf("%s", S);
for (int i = 0; i < 8; i = i + 2) {
if ((S[i] == 'h') && (S[i + 1] == 'i')) {
if (S[i + 2] == '\0') {
break;
}
continue;
}
printf("No\n");
return 0;
}
printf("Yes\n");
return 0;
} | [["-", 0, 57, 15, 23, 0, 16, 12, 103, 0, 125], ["+", 0, 57, 15, 23, 0, 16, 12, 103, 0, 44]] | 0 | 111 |
#include <bits/stdc++.h>
using namespace std;
int main() {
char S, pre;
cin >> S;
if (S != 'h') {
cout << "No" << endl;
return 0;
}
pre = S;
cin >> S;
while (1) {
if ((pre == 'i' && S == 'h') || (pre == 'h' && S == 'i')) {
pre = S;
cin >> S;
continue;
}
if (cin.eof()... | #include <bits/stdc++.h>
using namespace std;
int main() {
char S, pre;
cin >> S;
if (S != 'h') {
cout << "No" << endl;
return 0;
}
pre = S;
cin >> S;
while (1) {
if ((pre == 'i' && S == 'h') || (pre == 'h' && S == 'i')) {
pre = S;
cin >> S;
continue;
}
if (cin.eof()... | [["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 31, 22], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 60], ["+", 15, 339, 51, 16, 12, 16, 12, 103, 0, 104], ["+", 15, 339, 51, 16, 12, 16, 12, 103, 0, 125]] | 1 | 130 |
S = input()
S.replace("hi","")
if S == "":
print("Yes")
else:
print("No")
| S = input()
S = S.replace("hi","")
if S == "":
print("Yes")
else:
print("No") | [["+", 36, 36, 0, 656, 0, 1, 0, 662, 0, 32], ["+", 0, 1, 0, 662, 12, 652, 63, 319, 500, 22]] | 5 | 36 |
S=input().split("hi")
flag=False
for i in S:
if i:
continue
else:
flag=True
if flag:
print("Yes")
else:
print("No")
| S=input().split("hi")
flag=False
for i in S:
if i =="":
continue
else:
flag=True
if flag:
print("No")
else:
print("Yes")
| [["+", 0, 7, 8, 196, 0, 57, 15, 666, 667, 60], ["+", 8, 196, 0, 57, 15, 666, 0, 557, 0, 654], ["+", 8, 196, 0, 57, 15, 666, 0, 557, 0, 655], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 46 |
S=input()
hi="hi"
for i in range(5):
if(S==hi*i):
print("Yes")
exit()
print("No") | S=input()
hi="hi"
for i in range(1,6):
if(S==hi*i):
print("Yes")
exit()
print("No") | [["-", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 0, 656, 0, 7, 12, 652, 3, 4, 0, 21]] | 5 | 42 |
# -*- coding: utf-8 -*-
# 整数の入力
a = list(input())
#print(a)
Flag=True
if a.count('h')+a.count('i')!=len(a):
Flag = False
if a[0::2].count('h')!=len(a)/2:
print('a')
Flag = False
if a[1::2].count('i')!=len(a)/2:
Flag = False
if Flag:print('Yes')
else:print('No')
| # -*- coding: utf-8 -*-
# 整数の入力
a = list(input())
#print(a)
Flag=True
if a.count('h')+a.count('i')!=len(a):
Flag = False
if a[0::2].count('h')!=len(a)/2:
Flag = False
if a[1::2].count('i')!=len(a)/2:
Flag = False
if Flag:print('Yes')
else:print('No')
| [["-", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655], ["-", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 116 |
s = gets
if s.gsub!(/hi/, '')==''
puts 'Yes'
else
puts 'No'
end
| s = gets
if s.chop.gsub!(/hi/, '')==''
puts 'Yes'
else
puts 'No'
end | [["+", 0, 121, 15, 738, 31, 652, 486, 652, 735, 22], ["+", 0, 493, 0, 121, 15, 738, 31, 652, 17, 131]] | 4 | 28 |
import re
s = str(input())
m = re.match(pattern='(hi)+', string=s)
if m:
print('Yes')
else:
print('No') | import re
s = str(input())
m = re.fullmatch(pattern='(hi)+', string=s)
if m:
print('Yes')
else:
print('No') | [["-", 0, 1, 0, 662, 12, 652, 63, 319, 319, 22], ["+", 0, 1, 0, 662, 12, 652, 63, 319, 319, 22]] | 5 | 43 |
#include <stdio.h>
#include <string.h>
int main(void) {
char s[100];
int len;
int flag = 0;
int k;
scanf("%s", s);
len = strlen(s);
for (k = 0; k < len; k++) {
if (k % 2 == 0) {
if (s[k] != 'h') {
flag = 1;
break;
}
}
if (k % 2 == 1) {
if (s[k] != 'i') {
... | #include <stdio.h>
#include <string.h>
int main(void) {
char s[100];
int len;
int flag = 0;
int k;
scanf("%s", s);
len = strlen(s);
for (k = 0; k < len; k++) {
if (k % 2 == 0) {
if (s[k] != 'h') {
flag = 1;
break;
}
}
if (k % 2 == 1) {
if (s[k] != 'i') {
... | [["+", 0, 16, 31, 23, 0, 16, 31, 23, 0, 24], ["-", 15, 23, 0, 16, 31, 23, 0, 16, 17, 79], ["-", 15, 23, 0, 16, 31, 23, 0, 16, 12, 13], ["+", 31, 23, 0, 16, 31, 23, 0, 16, 17, 109], ["+", 31, 23, 0, 16, 31, 23, 0, 16, 12, 13], ["+", 0, 16, 31, 23, 0, 16, 31, 23, 0, 25], ["+", 15, 23, 0, 16, 31, 23, 0, 16, 17, 60], ["+",... | 0 | 153 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
char[] c = sc.next().toCharArray();
boolean flag = true;
if (c.length == 1) {
System.out.println("No");
return;
}
for (int i = 0; i < c.length; i++) {
... |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
char[] c = sc.next().toCharArray();
boolean flag = true;
if (c.length % 2 == 1) {
System.out.println("No");
return;
}
for (int i = 0; i < c.length; i++)... | [["+", 0, 57, 15, 15, 0, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 15, 0, 16, 31, 16, 12, 499]] | 3 | 165 |
import math
s = input()
n = math.ceil(len(s)/2)
hitachi = ""
for i in range(n):
hitachi += "hi"
print(hitachi)
if hitachi in s:
print("Yes")
else:
print("No") | import math
s = input()
n = math.ceil(len(s)/2)
hitachi = ""
for i in range(n):
hitachi += "hi"
if hitachi in s:
print("Yes")
else:
print("No") | [["-", 36, 36, 0, 656, 0, 1, 0, 652, 63, 22], ["-", 0, 656, 0, 1, 0, 652, 3, 4, 0, 24], ["-", 0, 656, 0, 1, 0, 652, 3, 4, 0, 22], ["-", 0, 656, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 60 |
#include <iostream>
using namespace std;
char S[100];
int main() {
int n = 1;
char C;
scanf("%c", &C);
while (C != 10) {
S[n++] = C;
scanf("%c", &C);
}
if (n % 2 == 0) {
printf("No");
return 0;
}
// cout<< n;
for (int i = 1; i <= n; i += 2) {
// cout << S[i] << " " << S[i + 1] <<... | #include <iostream>
using namespace std;
char S[100];
int main() {
int n = 1;
char C;
scanf("%c", &C);
while (C != 10) {
S[n++] = C;
scanf("%c", &C);
};
if (n % 2 == 0) {
printf("No");
return 0;
}
for (int i = 1; i < n; i += 2) {
if (S[i] != 'h' || S[i + 1] != 'i') {
printf("... | [["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35], ["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18]] | 1 | 145 |
# inputs = list(map(int, (input().split())))
a = input()
hi = "hi"
for i in range(5):
if a == hi:
print("Yes")
exit(0)
hi = hi + hi
print("No")
| # inputs = list(map(int, (input().split())))
a = input()
hi = "hi"
for i in range(5):
if a == hi:
print("Yes")
exit(0)
hi = hi + "hi"
print("No")
| [["+", 0, 1, 0, 662, 12, 657, 12, 557, 0, 654], ["+", 0, 1, 0, 662, 12, 657, 12, 557, 0, 655]] | 5 | 45 |
string = gets.chomp # hihi とか hhhi
if
string == "hihihihihi" ||
string == "hihihihi" ||
string == "hihihi" ||
string == "hihi" ||
string == "hi" then
puts "yes"
else
puts "No"
end
| string = gets.chomp # hihi とか hhhi
if string == "hihihihihi" ||string == "hihihihi" || string == "hihihi" || string == "hihi" || string == "hi" then
puts "Yes"
else
puts "No"
end | [["-", 64, 749, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 64, 749, 0, 652, 3, 4, 0, 557, 0, 6]] | 4 | 47 |
s = input()
h_else_i = True
ret = True
for char in s:
if h_else_i:
if char == "h":
h_else_i = not h_else_i
continue
else:
ret = False
break
else:
if char == "i":
h_else_i = not h_else_i
continue
else:
ret = False
break
if ret:
print("Yes")
else:
p... | s = input()
h_else_i = True
ret = True
for char in s:
if h_else_i:
if char == "h":
h_else_i = not h_else_i
continue
else:
ret = False
break
else:
if char == "i":
h_else_i = not h_else_i
continue
else:
ret = False
break
if ret and h_else_i:
print("Y... | [["+", 36, 36, 0, 656, 0, 57, 15, 679, 17, 355], ["+", 36, 36, 0, 656, 0, 57, 15, 679, 12, 22]] | 5 | 74 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
using P = pair<int, int>;
int main() {
string s;
cin >> s;
bool flag = true;
for (int i = 0; i < s.length(); i = i + 2) {
if (s.at(i) != 'h' || s.at(i + 1) != 'i') {
flag = false;
}
}
if (s.... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
using P = pair<int, int>;
int main() {
string s;
cin >> s;
bool flag = true;
for (int i = 0; i < s.length() - 1; i = i + 2) {
if (s.at(i) != 'h' || s.at(i + 1) != 'i') {
flag = false;
}
}
if... | [["+", 8, 9, 0, 7, 15, 16, 12, 16, 17, 33], ["+", 8, 9, 0, 7, 15, 16, 12, 16, 12, 13]] | 1 | 134 |
s = input()
if len(s) % 2 == 0:
ans = True
for i in range(len(s)//2):
if s[2*i] != "h" or s[2*i+1] != "i":
ans = False
print("No")
if ans:
print("Yes")
else:
print("No")
| s = input()
if len(s) % 2 == 0:
ans = True
for i in range(len(s)//2):
if s[2*i] != "h" or s[2*i+1] != "i":
ans = False
print("No")
break
if ans:
print("Yes")
else:
print("No")
| [["+", 8, 196, 0, 57, 64, 196, 0, 93, 0, 94]] | 5 | 82 |
S = input()
import re
if re.match(r'(hi)+',S):
print('Yes')
else:
print('No') | S = input()
import re
if re.fullmatch(r'(hi)+',S):
print('Yes')
else:
print('No') | [["-", 0, 656, 0, 57, 15, 652, 63, 319, 319, 22], ["+", 0, 656, 0, 57, 15, 652, 63, 319, 319, 22]] | 5 | 33 |
#include <algorithm>
#include <cmath>
#include <iostream>
#include <set>
#include <string>
#include <vector>
using namespace std;
int main() {
string st;
cin >> st;
if (st.length() > 1) {
for (int i = 0; i < st.length(); i++) {
if (i % 2 == 0 && st[i] == 'h') {
} else if (i % 2 == 1 && st[i] == '... | #include <algorithm>
#include <cmath>
#include <iostream>
#include <set>
#include <string>
#include <vector>
using namespace std;
int main() {
string st;
cin >> st;
if (st.length() % 2 == 0) {
for (int i = 0; i < st.length(); i++) {
if (i % 2 == 0 && st[i] == 'h') {
} else if (i % 2 == 1 && st[i]... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 47], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 145 |
main() { system("egrep -q '^(hi)*$' && echo YES || echo NO"); } | main() { system("egrep -q '^(hi)*$' && echo Yes || echo No"); } | [["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 0 | 12 |
puts gets[/^(hi)+/] ? :Yes : :No | puts gets[/^(hi)+$/] ? :Yes : :No | [["-", 3, 4, 0, 754, 15, 742, 0, 575, 0, 6], ["+", 3, 4, 0, 754, 15, 742, 0, 575, 0, 6]] | 4 | 11 |
#include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define INF 9223372036854775807
#define endl '\n'
#define pii pair<ll int, ll int>
#define vi vector<ll int>
#define all(a) (a).begin(), (a).end()
#define F first
#define S second
#define sz(x) (ll int)x.size()
#define hell 1000000007
#define rep(i, a, ... | #include <bits/stdc++.h>
#define ll long long
#define pb push_back
#define INF 9223372036854775807
#define endl '\n'
#define pii pair<ll int, ll int>
#define vi vector<ll int>
#define all(a) (a).begin(), (a).end()
#define F first
#define S second
#define sz(x) (ll int)x.size()
#define hell 1000000007
#define rep(i, a, ... | [["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["-", 0, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 0, 9, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 250 |
x = input()
y = "hi"
for i in range(4):
if y == x:
print("Yes")
break
y = y + "hi"
else:
print("No") | x = input()
y = "hi"
for i in range(5):
if y == x:
print("Yes")
break
y = y + "hi"
else:
print("No") | [["-", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612]] | 5 | 45 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
typedef unsigned long long ll;
const int INF = 1001001001;
const int dx[] = {-1, 0, 1, 0};
const int dy[] = {0, -1, 0, 1};
int main() {
// int n, m;
string s;
// cin >> n >> m;
cin >> s;
int size = s.size(... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
typedef unsigned long long ll;
const int INF = 1001001001;
const int dx[] = {-1, 0, 1, 0};
const int dy[] = {0, -1, 0, 1};
int main() {
// int n, m;
string s;
// cin >> n >> m;
cin >> s;
int size = s.size(... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 189 |
#include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
string s, hi = "hi";
cin >> s;
for (int i = 0; i < 10; i++) {
// cout<<hi<<endl;
if (s == hi) {
cout << "Yes" << endl;
// cout<<"BTREA"<<endl;
break;
} else {
hi += hi... | #include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
string s, hi = "hi";
cin >> s;
for (int i = 0; i < 12; i++) {
// cout<<hi<<endl;
if (s == hi) {
cout << "Yes" << endl;
// cout<<"BTREA"<<endl;
break;
} else {
hi += "h... | [["-", 0, 14, 8, 9, 0, 7, 15, 16, 12, 13], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 12, 13], ["+", 0, 9, 0, 1, 0, 11, 12, 5, 0, 62]] | 1 | 93 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
bool flag = true;
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 0) {
if (s.at(i) != 'h') {
flag = false;
break;
}
} else {
if (s.at(i) != 'i') {
flag = false;
break;
... | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
bool flag = true;
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 0) {
if (s.at(i) != 'h') {
flag = false;
break;
}
} else {
if (s.at(i) != 'i') {
flag = false;
break;
... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 132 |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
string s;
cin >> s;
bool j = true;
// cout<<s.size()<<endl;
if (s.size() == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 0) {
if (s.at(i) == 'h') {
continu... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
string s;
cin >> s;
bool j = true;
// cout<<s.size()<<endl;
if (s.size() % 2 == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 0) {
if (s.at(i) == 'h') {
con... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 161 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
int c = 0;
for (int i = 0; i < s.size() - 1; i += 2) {
if (s[i] == 'h' && s[i + 1] == 'i' && s[i + 2] != 'i')
c = 1;
else {
c = 0;
break;
}
}
if (c)
printf("Yes\n");
else
printf("No\n");
} | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
int c = 0;
for (int i = 0; i < s.size(); i += 2) {
if (s[i] == 'h' && s[i + 1] == 'i' && s[i + 2] != 'i')
c = 1;
else {
c = 0;
break;
}
}
if (c)
printf("Yes\n");
else
printf("No\n");
} | [["-", 8, 9, 0, 7, 15, 16, 12, 16, 17, 33], ["-", 8, 9, 0, 7, 15, 16, 12, 16, 12, 13]] | 1 | 114 |
#include <iostream>
using namespace std;
int main() {
string S;
cin >> S;
string out = "Yes";
if (S.length() < 2) {
out = "No";
} else {
for (int i = 0; i < S.length(); i++) {
if (i % 2 == 0) {
if (S[i] != 'h') {
out = "No";
break;
}
} else {
i... | #include <iostream>
using namespace std;
int main() {
string S;
cin >> S;
string out = "Yes";
if (S.length() % 2 != 0) {
out = "No";
} else {
for (int i = 0; i < S.length(); i++) {
if (i % 2 == 0) {
if (S[i] != 'h') {
out = "No";
break;
}
} else {
... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 128 |
s=input()
b=s.strip('hi')
if len(s)==1:
print("No")
else:
if b=="":
print("Yes")
else:
print("No") | s=input()
b=s.replace('hi','')
if len(s)==1:
print("No")
else:
if b=="":
print("Yes")
else:
print("No") | [["-", 0, 1, 0, 662, 12, 652, 63, 319, 319, 22], ["+", 0, 1, 0, 662, 12, 652, 63, 319, 319, 22], ["+", 0, 662, 12, 652, 3, 4, 0, 557, 0, 655], ["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 21], ["+", 0, 662, 12, 652, 3, 4, 0, 557, 0, 654]] | 5 | 51 |
#include <iostream>
using namespace std;
int main() {
string s;
bool judge = 1;
cin >> s;
if (s.size() == 0) {
judge = 0;
}
for (int i = 0; i < s.size(); i++) {
if (((i % 2 == 0) && (s[i] != 'h')) || ((i % 2 == 1) && (s[i] != 'i'))) {
judge = 0;
break;
}
}
if (judge) {
cout... | #include <iostream>
using namespace std;
int main() {
string s;
bool judge = 1;
cin >> s;
if (s.size() % 2 != 0) {
judge = 0;
} else {
for (int i = 0; i < s.size(); i++) {
if (((i % 2 == 0) && (s[i] != 'h')) || ((i % 2 == 1) && (s[i] != 'i'))) {
judge = 0;
break;
}
}
... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 0, 14, 8, 9, 0, 57, 75, 76, 0, 95], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 45], ["+", 0, 7, 8, 9, 0, 57, 64, 9, 0, 46]] | 1 | 140 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
int j = 0;
int check = 0;
cin >> S;
for (int i = 0; i < S.length(); i++) {
if (j == 0) {
if (S.at(i) == 'h') {
j = 1;
} else {
check = 1;
break;
}
} else {
if (S.at(i) == 'i') {
... | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
int j = 0;
int check = 0;
cin >> S;
for (int i = 0; i < S.length(); i++) {
if (j == 0) {
if (S.at(i) == 'h') {
j = 1;
} else {
check = 1;
break;
}
} else {
if (S.at(i) == 'i') {
... | [["-", 15, 339, 51, 16, 31, 2, 63, 118, 28, 22], ["-", 15, 339, 51, 16, 31, 2, 63, 118, 17, 131], ["-", 15, 339, 51, 16, 31, 2, 63, 118, 119, 120], ["-", 15, 339, 51, 16, 31, 2, 3, 4, 0, 24], ["-", 15, 339, 51, 16, 31, 2, 3, 4, 0, 25], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 31, 22], ["-", 75, 76, 0, 57, 15, 339, 51, 16,... | 1 | 164 |
#include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
std::string s;
cin >> s;
bool b = true;
if (s.size() == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.size(); i++) {
if (b == true) {
if (s[i] != 'h') {
co... | #include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
std::string s;
cin >> s;
bool b = true;
if (s.size() % 2 != 0) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.size(); i++) {
if (b == true) {
if (s[i] != 'h') {
... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 150 |
import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
Scanner sc = new Scanner(System.in);
String s = sc.next();
int l = s.length();
boolean flag = (l % 2 == 0);
for (int i = 2; i < l; i += 2) {
if (!s.substring(i - 2, i).equals(... | import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
Scanner sc = new Scanner(System.in);
String s = sc.next();
int l = s.length();
boolean flag = (l % 2 == 0);
for (int i = 1; i < l; i += 2) {
if (!s.substring(i - 1, i + 1).equ... | [["-", 8, 196, 0, 7, 502, 503, 49, 200, 51, 499], ["+", 8, 196, 0, 7, 502, 503, 49, 200, 51, 499], ["-", 439, 492, 500, 492, 3, 4, 0, 16, 12, 499], ["+", 439, 492, 500, 492, 3, 4, 0, 16, 12, 499], ["+", 439, 492, 500, 492, 3, 4, 0, 16, 17, 72]] | 3 | 146 |
#include <bits/stdc++.h>
using namespace std;
#define ifor(i, n) for (i = 0; i < n; i++)
#define ll long long
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
ll int i, n, t, p = INT_MAX, j = 0, x, a = 0, b, l = 0, r = 0;
string s, m;
cin >> s;
for (i = 0; i < s.size() - 1; i += 2) {
m = s.... | #include <bits/stdc++.h>
using namespace std;
#define ifor(i, n) for (i = 0; i < n; i++)
#define ll long long
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
ll int i, n, t, p = INT_MAX, j = 0, x, a = 0, b, l = 0, r = 0;
string s, m;
cin >> s;
for (i = 0; i < s.size(); i += 2) {
m = s.subs... | [["-", 8, 9, 0, 7, 15, 16, 12, 16, 17, 33], ["-", 8, 9, 0, 7, 15, 16, 12, 16, 12, 13]] | 1 | 146 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int c = 0;
for (int i = 0; i < S.length(); i = i + 2) {
if (S.length() == 1) {
break;
}
if (S.at(i) == 'h' && S.at(i + 1) == 'i') {
c = c + 2;
}
}
if (c++ == S.length()) {
cout << "Yes" << endl;
... | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int c = 0;
// cout << S.length();
for (int i = 0; i < S.length(); i = i + 2) {
if (S.length() % 2 == 1) {
break;
}
if (S.at(i) == 'h' && S.at(i + 1) == 'i') {
c = c + 2;
}
}
if (c == S.length()) ... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["-", 0, 57, 15, 339, 51, 16, 31, 27, 17, 29]] | 1 | 127 |
S = input()
for i in range(1,6):
if S is 'hi'*i:
print('Yes')
break
else:
print('No') | S = input()
for i in range(1,6):
if S == 'hi'*i:
print('Yes')
break
else:
print('No') | [["-", 0, 7, 8, 196, 0, 57, 15, 666, 667, 709], ["+", 0, 7, 8, 196, 0, 57, 15, 666, 667, 60]] | 5 | 39 |
s=input()
if s=='hi':
print(Yes)
elif s=='hihi':
print(Yes)
elif s=='hihihi':
print(Yes)
elif s=='hihihihi':
print(Yes)
elif s=='hihihihihi':
print(Yes)
else:
print(No) | s=input()
if s=='hi':
print('Yes')
elif s=='hihi':
print('Yes')
elif s=='hihihi':
print('Yes')
elif s=='hihihihi':
print('Yes')
elif s=='hihihihihi':
print('Yes')
else:
print('No') | [["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]] | 5 | 66 |
#include <bits/stdc++.h>
#define STDIO
#define MOD 1000000007
#define testbit(mask, i) (((mask) >> (i)) & 1)
#define setbit(mask, i) ((mask) | (1 << i))
#define delbit(mask, i) ((mask) ^ (1 << i))
#define lowbit(x) ((x) & (-x))
#define INF MOD
using namespace std;
string s;
int main() {
#ifndef STDIO
freopen("input.i... | #include <bits/stdc++.h>
#define STDIO
#define MOD 1000000007
#define testbit(mask, i) (((mask) >> (i)) & 1)
#define setbit(mask, i) ((mask) | (1 << i))
#define delbit(mask, i) ((mask) ^ (1 << i))
#define lowbit(x) ((x) & (-x))
#define INF MOD
using namespace std;
string s;
int main() {
#ifndef STDIO
freopen("input.i... | [["-", 8, 9, 0, 57, 64, 9, 0, 116, 0, 117], ["+", 8, 9, 0, 57, 64, 9, 0, 37, 0, 38], ["+", 8, 9, 0, 57, 64, 9, 0, 37, 0, 13]] | 1 | 209 |
<?php
// 末尾に改行をつけて出力
function output($str) {
echo $str . PHP_EOL;
}
$s = trim(fgets(STDIN));
if (count(explode('hi', $s)) > 1) {
output('Yes');
} else {
output('No');
}
| <?php
// 末尾に改行をつけて出力
function output($str) {
echo $str . PHP_EOL;
}
$s = trim(fgets(STDIN));
if (implode('', explode('hi', $s)) == '') {
output('Yes');
} else {
output('No');
}
| [["-", 0, 57, 15, 23, 0, 16, 31, 613, 63, 141], ["+", 0, 57, 15, 23, 0, 16, 31, 613, 63, 141], ["+", 31, 613, 3, 3, 0, 28, 0, 557, 0, 104], ["+", 15, 23, 0, 16, 31, 613, 3, 3, 0, 21], ["-", 0, 493, 0, 57, 15, 23, 0, 16, 17, 47], ["-", 0, 493, 0, 57, 15, 23, 0, 16, 12, 612], ["+", 0, 493, 0, 57, 15, 23, 0, 16, 17, 60], ... | 6 | 63 |
#include <bits/stdc++.h>
using namespace std;
int main() {
int Q, A, F;
string S;
cin >> S;
for (int lp = 0; lp < (int)S.length() - 1; lp += 2) {
string s = S.substr(lp, 2);
if (s == "hi")
continue;
else {
cout << "No" << endl;
return 0;
}
}
cout << "Yes" << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int Q, A, F;
string S;
cin >> S;
for (int lp = 0; lp < (int)S.length(); lp += 2) {
string s = S.substr(lp, 2);
if (s == "hi")
continue;
else {
cout << "No" << endl;
return 0;
}
}
cout << "Yes" << endl;
} | [["-", 8, 9, 0, 7, 15, 16, 12, 16, 17, 33], ["-", 8, 9, 0, 7, 15, 16, 12, 16, 12, 13]] | 1 | 96 |
#include <iostream>
#include <string>
using namespace std;
int main() {
string s;
bool flag;
cin >> s;
if (s.size() % 2 == 1) {
cout << "No" << endl;
return 0;
}
string st;
for (int i = 0; i != s.size(); i + 2) {
st += "hi";
}
if (s == st) {
cout << "Yes" << endl;
} else {
cout <... | // A.cpp
#include <iostream>
#include <string>
using namespace std;
int main() {
string s;
bool flag;
cin >> s;
if (s.size() % 2 == 1) {
cout << "No" << endl;
return 0;
}
string st;
for (int i = 0; i != s.size(); i += 2) {
st += "hi";
}
if (s == st) {
cout << "Yes" << endl;
} else {... | [["-", 0, 14, 8, 9, 0, 7, 26, 16, 17, 72], ["+", 0, 14, 8, 9, 0, 7, 26, 11, 17, 107]] | 1 | 106 |
s = gets.chomp
puts s.gsub('hi', '').empty? ? 'YES' : 'NO'
| s = gets.chomp
puts s.gsub('hi', '').empty? ? 'Yes' : 'No'
| [["-", 0, 652, 3, 4, 0, 754, 64, 557, 0, 6], ["+", 0, 652, 3, 4, 0, 754, 64, 557, 0, 6], ["-", 0, 652, 3, 4, 0, 754, 75, 557, 0, 6], ["+", 0, 652, 3, 4, 0, 754, 75, 557, 0, 6]] | 4 | 27 |
#include <bits/stdc++.h>
using namespace std;
int main() {
char S[16];
bool flg = true;
int size = 0;
cin >> S;
for (int i = 0; i < 14; i++) {
if (S[i] == '\0') {
size = i;
break;
}
}
if (size % 2 == 0) {
for (int i = 0; i < size / 2; i++) {
if (S[i] != 'h' || S[i + 1] != 'i'... | #include <bits/stdc++.h>
using namespace std;
int main() {
char S[16];
bool flg = true;
int size = 0;
cin >> S;
for (int i = 0; i < 14; i++) {
if (S[i] == '\0') {
size = i;
break;
}
}
if (size % 2 == 0) {
for (int i = 0; i < size / 2; i++) {
if (S[2 * i] != 'h' || S[2 * i + 1... | [["+", 31, 16, 31, 69, 341, 342, 0, 16, 31, 13], ["+", 31, 16, 31, 69, 341, 342, 0, 16, 17, 48], ["+", 31, 69, 341, 342, 0, 16, 31, 16, 31, 13], ["+", 31, 69, 341, 342, 0, 16, 31, 16, 17, 48]] | 1 | 152 |
// Nicky's template
// C
#include <inttypes.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
// C++
#include <algorithm>
#include <deque>
#include <iostream>
#include <list>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <unordered_map>
#include... | // Nicky's template
// C
#include <inttypes.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
// C++
#include <algorithm>
#include <deque>
#include <iostream>
#include <list>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <unordered_map>
#include... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 19], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60]] | 1 | 1,301 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int size = S.size();
if (size < 2 || size > 10) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < size; ++i) {
if (i % 2 == 0 && S.at(i) != 'h') {
cout << "No" << endl;
return 0;
}
if (i % ... | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int size = S.size();
if (size < 2 || size % 2) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < size; ++i) {
if (i % 2 == 0 && S.at(i) != 'h') {
cout << "No" << endl;
return 0;
}
if (i % 2... | [["-", 0, 57, 15, 339, 51, 16, 12, 16, 17, 47], ["-", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13]] | 1 | 142 |
#include <bits/stdc++.h>
using namespace std;
#define itn int
#define int unsigned long long
#define mod 1000000007
#define fi first
#define se second
#define be begin()
#define en end()
#define re reverse
#define Set setprecision
#define NO cout << "NO\n"
#define YES cout << "YES\n"
#define No cout << "No\n"
#define Y... | #include <bits/stdc++.h>
using namespace std;
#define itn int
#define int unsigned long long
#define mod 1000000007
#define fi first
#define se second
#define be begin()
#define en end()
#define re reverse
#define Set setprecision
#define NO cout << "NO\n"
#define YES cout << "YES\n"
#define No cout << "No\n"
#define Y... | [["-", 0, 7, 8, 9, 0, 1, 0, 11, 12, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 5, 0, 62], ["+", 8, 9, 0, 1, 0, 11, 12, 5, 0, 6]] | 1 | 127 |
#include <iostream>
#include <regex>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
if (regex_search(s, regex("(hi)+"))) {
cout << "Yes";
} else {
cout << "No";
}
} | #include <iostream>
#include <regex>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
if (regex_match(s, regex("(hi)+"))) {
cout << "Yes";
} else {
cout << "No";
}
} | [["-", 8, 9, 0, 57, 15, 339, 51, 2, 63, 22], ["+", 8, 9, 0, 57, 15, 339, 51, 2, 63, 22]] | 1 | 54 |
import sys
s = list(input())
c = len(s)
if c%2 == 1:
print("No")
sys.exit()
else:
for i in range(c//2):
if not s[2*i] == "h" and s[2*i+1] == "i":
print("No")
sys.exit
print("Yes") | import sys
s = list(input())
c = len(s)
if c%2 == 1:
print("No")
sys.exit()
else:
for i in range(c//2):
if s[2*i] != "h" or s[2*i+1] != "i":
print("No")
sys.exit()
print("Yes") | [["-", 8, 196, 0, 57, 15, 679, 31, 681, 0, 372], ["-", 0, 57, 15, 679, 31, 681, 28, 666, 667, 60], ["+", 8, 196, 0, 57, 15, 679, 31, 666, 667, 79], ["-", 0, 7, 8, 196, 0, 57, 15, 679, 17, 355], ["+", 0, 7, 8, 196, 0, 57, 15, 679, 17, 354], ["-", 8, 196, 0, 57, 15, 679, 12, 666, 667, 60], ["+", 8, 196, 0, 57, 15, 679, 1... | 5 | 87 |
#include <bits/stdc++.h>
typedef long long ll;
#define rep(i, n) for (int i = 0; i < n; i++)
#define per(i, n) for (int i = n - 1; i >= 0; i--)
#define rep1(i, n) for (int i = 1; i <= n; i++)
#define per1(i, n) for (int i = n; i >= 1; i--)
const ll INF = (ll)1e18 + 1;
const long double pi = 3.14159265358979323846264338... | #include <bits/stdc++.h>
typedef long long ll;
#define rep(i, n) for (int i = 0; i < n; i++)
#define per(i, n) for (int i = n - 1; i >= 0; i--)
#define rep1(i, n) for (int i = 1; i <= n; i++)
#define per1(i, n) for (int i = n; i >= 1; i--)
const ll INF = (ll)1e18 + 1;
const long double pi = 3.14159265358979323846264338... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 225 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
ll gcd(ll x, ll y) {
if (y == 0)
return x;
else
return gcd(y, x % y);
}
ll lcm(ll x, ll y) { return x / gcd(x, y) * y; }
using namespace std;
int main() {
string s;
cin >> s;
bool flag = true;
rep(i, s.siz... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
typedef long long ll;
ll gcd(ll x, ll y) {
if (y == 0)
return x;
else
return gcd(y, x % y);
}
ll lcm(ll x, ll y) { return x / gcd(x, y) * y; }
using namespace std;
int main() {
string s;
cin >> s;
bool flag = true;
rep(i, s.siz... | [["-", 0, 1, 0, 2, 3, 4, 0, 16, 17, 33], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 12, 13]] | 1 | 182 |
puts(/\A(hi)+\z/.match(gets) ? :Yes : :No)
| puts(/\A(hi)+\Z/.match(gets) ? :Yes : :No)
| [["-", 3, 4, 0, 754, 15, 652, 486, 575, 0, 44], ["+", 3, 4, 0, 754, 15, 652, 486, 575, 0, 44]] | 4 | 17 |
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iomanip>
#include <iostream>
using namespace std;
// int ksm(int a,int b){
// int ans = 1;
// while(b){
// if(b&1){
// ans = ans*a;
// }
// a = a*a;
// b>>=1;
// }
// return ans;
//}
int main() {
string a;
cin >> a;
int flag = 0;
int len = a.... | #include <cmath>
#include <cstdio>
#include <cstring>
#include <iomanip>
#include <iostream>
using namespace std;
// int ksm(int a,int b){
// int ans = 1;
// while(b){
// if(b&1){
// ans = ans*a;
// }
// a = a*a;
// b>>=1;
// }
// return ans;
//}
int main() {
string a;
cin >> a;
int flag = 0;
int len = a.... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 176 |
#include <bits/stdc++.h>
using namespace std;
// Order statistics tree (if supported by judge!):
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// using namespace __gnu_pbds;
// template<class TK, class TM> using order_tree = tree<TK, TM, less<TK>,
// rb_tree_tag, tree_order_stati... | #include <bits/stdc++.h>
using namespace std;
// Order statistics tree (if supported by judge!):
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// using namespace __gnu_pbds;
// template<class TK, class TM> using order_tree = tree<TK, TM, less<TK>,
// rb_tree_tag, tree_order_stati... | [["-", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 64, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]] | 1 | 424 |
#include <bits/stdc++.h>
#include <complex>
#include <vector>
#define ll long long
#define ld long double
#define fast \
ios_base::sync_with_stdio(0); \
cin.tie(NULL); ... | #include <bits/stdc++.h>
#include <complex>
#include <vector>
#define ll long long
#define ld long double
#define fast \
ios_base::sync_with_stdio(0); \
cin.tie(NULL); ... | [["-", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46]] | 1 | 148 |
#include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
string S;
cin >> S;
bool ans = true;
int cnt = 0;
for (int i = 0; i < S.size(); i++) {
if (cnt % 2 == 0) {
if (S.at(i) != 'h') {
ans = false;
break;
}
} else {
... | #include <algorithm>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main() {
string S;
cin >> S;
bool ans = true;
int cnt = 0;
for (int i = 0; i < S.size(); i++) {
if (cnt % 2 == 0) {
if (S.at(i) != 'h') {
ans = false;
break;
}
} else {
... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 153 |
#include <iostream>
using namespace std;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
char c;
bool h = true;
while (cin >> c) {
if (h && c == 'h') {
h = false;
} else if (!h && c == 'i') {
h = true;
} else {
h = true;
break;
}
}
if (h) {
cout << "No"
... | #include <iostream>
using namespace std;
int main() {
cin.tie(0);
ios::sync_with_stdio(false);
char c;
bool h = true;
while (cin >> c) {
if (h && c == 'h') {
h = false;
} else if (!h && c == 'i') {
h = true;
} else {
h = false;
break;
}
}
if (!h) {
cout << "No"... | [["-", 75, 76, 0, 9, 0, 1, 0, 11, 12, 146], ["+", 75, 76, 0, 9, 0, 1, 0, 11, 12, 147], ["+", 8, 9, 0, 57, 15, 339, 51, 91, 17, 111]] | 1 | 117 |
/* Code by pedroslrey *
* march 8 *
* Sunday */
#include <bits/stdc++.h>
using namespace std;
using lli = long long int;
const int INF = 1000000007;
const lli LLINF = 9223372036854775800;
#define debug(args...) fprintf(stderr, args)
#define show(x) fprintf(stderr, "[DEBUG] -> %d\n", x)
in... | /* Code by pedroslrey *
* march 8 *
* Sunday */
#include <bits/stdc++.h>
using namespace std;
using lli = long long int;
const int INF = 1000000007;
const lli LLINF = 9223372036854775800;
#define debug(args...) fprintf(stderr, args)
#define show(x) fprintf(stderr, "[DEBUG] -> %d\n", x)
in... | [["+", 0, 14, 8, 9, 0, 57, 75, 76, 0, 95]] | 1 | 139 |
// love yjl forever
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define pii pair<int, int>
#define mp make_pair
#define pb push_back
#define fi first
#define se second
const int INF = 0x3f3f3f3f;
int n;
int main() {
/* freopen("","r",stdin);
freopen("","w",stdout);*/
int i;
string... | // love yjl forever
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define pii pair<int, int>
#define mp make_pair
#define pb push_back
#define fi first
#define se second
const int INF = 0x3f3f3f3f;
int n;
int main() {
/* freopen("","r",stdin);
freopen("","w",stdout);*/
int i;
string... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 176 |
S = list(str(input()))
status = 0
det = 0
for i in range(len(S)):
if status == 0 and S[i] != "h":
det = -1
break
elif status == 1 and S[i] != "i":
det = -1
break
status += 1
status %= 2
if det == 0:
print("Yes")
else:
print("No") | S = list(str(input()))
status = 0
det = 0
for i in range(len(S)):
if status == 0 and S[i] != "h":
det = -1
break
elif status == 1 and S[i] != "i":
det = -1
break
status += 1
status %= 2
if det == 0 and status == 0:
print("Yes")
else:
print("No") | [["+", 36, 36, 0, 656, 0, 57, 15, 679, 17, 355], ["+", 0, 656, 0, 57, 15, 679, 12, 666, 0, 22], ["+", 0, 656, 0, 57, 15, 679, 12, 666, 667, 60], ["+", 0, 656, 0, 57, 15, 679, 12, 666, 0, 612]] | 5 | 91 |
#include <stdio.h>
int main(void) {
char s[12];
int i, c = 0;
scanf("%s", s);
for (i = 0; s[i] != '\0'; i++) {
if ((i % 2 == 0) && (s[i] != 'h'))
c = 1;
else if ((i % 2 == 1) && (s[1] != 'i'))
c = 1;
}
if (i % 2 == 0)
c = 1;
printf(c == 0 ? "Yes" : "No");
return 0;
} | #include <stdio.h>
int main(void) {
char s[12];
int i, c = 0;
scanf("%s", s);
for (i = 0; s[i] != '\0'; i++) {
if ((i % 2 == 0) && (s[i] != 'h'))
c = 1;
else if ((i % 2 == 1) && (s[i] != 'i'))
c = 1;
}
if (i % 2 == 1)
c = 1;
printf(c == 0 ? "Yes" : "No");
return 0;
} | [["-", 0, 16, 12, 23, 0, 16, 31, 69, 71, 13], ["+", 0, 16, 12, 23, 0, 16, 31, 69, 71, 22], ["-", 8, 9, 0, 57, 15, 23, 0, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 23, 0, 16, 12, 13]] | 0 | 132 |
#include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define mp make_pair
#define rt return 0
#define endln "\n"
#define for1(i, a, b) for (long long int i = a; i < b; i++)
#define for2(i, a, b) for (long long int i = a; i > b; i--)
// cout << fixed << setprecision(0) << pi <<" "<<npi<<endl;typedef long ... | #include <bits/stdc++.h>
using namespace std;
#define pb push_back
#define mp make_pair
#define rt return 0
#define endln "\n"
#define for1(i, a, b) for (long long int i = a; i < b; i++)
#define for2(i, a, b) for (long long int i = a; i > b; i--)
// cout << fixed << setprecision(0) << pi <<" "<<npi<<endl;typedef long ... | [["-", 0, 57, 15, 339, 51, 16, 12, 16, 17, 60], ["-", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13]] | 1 | 179 |
#include <bits/stdc++.h>
using namespace std;
#define debug(n) cerr << #n << ':' << n << endl;
#define dline cerr << __LINE__ << endl;
using ll = long long;
template <class T, class U> using P = pair<T, U>;
template <class T> using Heap = priority_queue<T>;
template <class T> using heaP = priority_queue<T, vector<T>... | #include <bits/stdc++.h>
using namespace std;
#define debug(n) cerr << #n << ':' << n << endl;
#define dline cerr << __LINE__ << endl;
using ll = long long;
template <class T, class U> using P = pair<T, U>;
template <class T> using Heap = priority_queue<T>;
template <class T> using heaP = priority_queue<T, vector<T>... | [["-", 51, 16, 31, 2, 3, 4, 0, 16, 31, 22], ["-", 51, 16, 31, 2, 3, 4, 0, 16, 17, 72]] | 1 | 376 |
package main
import (
"bufio"
"fmt"
"os"
"strconv"
)
func main() {
sc := NewScanner()
S := sc.Next()
if len(S)%2 == 0 {
fmt.Println("No")
return
}
for i := 0; i+1 < len(S); i += 2 {
if S[i] == 'h' && S[i+1] == 'i' {
} else {
fmt.Println("No")
return
}
}
fmt.Println("Yes")
}
type Scanner... | package main
import (
"bufio"
"fmt"
"os"
"strconv"
)
func main() {
sc := NewScanner()
S := sc.Next()
if len(S)%2 == 1 {
fmt.Println("No")
return
}
for i := 0; i+1 < len(S); i += 2 {
if S[i] == 'h' && S[i+1] == 'i' {
} else {
fmt.Println("No")
return
}
}
fmt.Println("Yes")
}
type Scanner... | [["-", 0, 435, 8, 196, 0, 57, 15, 16, 12, 433], ["+", 0, 435, 8, 196, 0, 57, 15, 16, 12, 433]] | 7 | 932 |
s = input()
flag = False
for i in range(1,5):
if 'hi' * i == s:
flag = True
if flag:
print('Yes')
else:
print('No') | s = input()
flag = False
for i in range(1,6):
if 'hi' * i == s:
flag = True
if flag:
print('Yes')
else:
print('No') | [["-", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612]] | 5 | 47 |
#include <algorithm>
#include <iomanip>
#include <iostream>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <string>
#include <tuple>
#include <vector>
#define rep(i, n) rep2(i, 0, n)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
#define PI acos(-1);
typedef long long ll;
usin... | #include <algorithm>
#include <iomanip>
#include <iostream>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <string>
#include <tuple>
#include <vector>
#define rep(i, n) rep2(i, 0, n)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
#define PI acos(-1);
typedef long long ll;
usin... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 168 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; i++)
#define FOR(i, start, end) for (int i = start; i <= end; i++)
const int INF = 1001001001;
using namespace std;
typedef long long ll;
int main() {
string S;
cin >> S;
string str = "hi";
FOR(i, 1, 4) {
if (S == str) {
cout << "Yes... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; i++)
#define FOR(i, start, end) for (int i = start; i <= end; i++)
const int INF = 1001001001;
using namespace std;
typedef long long ll;
int main() {
string S;
cin >> S;
string str = "hi";
FOR(i, 1, 5) {
if (S == str) {
cout << "Yes... | [["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 13], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 13]] | 1 | 99 |
#include <bits/stdc++.h>
using namespace std;
#define int long long
string s;
int c = 0;
int32_t main() {
cin >> s;
for (int i = 0; i < s.size(); i++) {
if (s[i] == 'h')
c++;
else if (s[i] == 'i')
c--;
else
c++;
if (c > 1 or c < 0)
break;
}
if (!c)
cout << "Yes\n";... | #include <bits/stdc++.h>
using namespace std;
#define int long long
string s;
int c = 0;
int32_t main() {
cin >> s;
for (int i = 0; i < s.size(); i++) {
if (s[i] == 'h')
c++;
else if (s[i] == 'i')
c--;
else
c += 5;
if (c > 1 or c < 0)
break;
}
if (!c)
cout << "Yes\... | [["-", 0, 57, 75, 76, 0, 1, 0, 27, 17, 29], ["+", 0, 57, 75, 76, 0, 1, 0, 11, 17, 107], ["+", 0, 57, 75, 76, 0, 1, 0, 11, 12, 13]] | 1 | 112 |
S = list(input())
N = len(S)
if N == 1:
print('No')
exit()
for i in range(0,N,2):
if S[i] != 'h' or S[i+1] != 'i':
print('No')
exit()
print('Yes')
| S = list(input())
N = len(S)
if N%2 == 1:
print('No')
exit()
for i in range(0,N,2):
if S[i] != 'h' or S[i+1] != 'i':
print('No')
exit()
print('Yes')
| [["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 109], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 12, 612]] | 5 | 76 |
require 'pp'
s = gets.chomp!
if s == "hi" || s == "hihi" || s == "hi" * 3 || s == "hi" * 4 || s == "h1" * 5
puts "Yes"
else
puts "No"
end
| require 'pp'
s = gets.chomp!
if s == "hi" || s == "hihi" || s == "hi" * 3 || s == "hi" * 4 || s == "hi" * 5
puts "Yes"
else
puts "No"
end
| [["-", 15, 738, 12, 738, 12, 738, 31, 557, 0, 6], ["+", 15, 738, 12, 738, 12, 738, 31, 557, 0, 6]] | 4 | 55 |
#include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <string.h>
using namespace std;
char s[400005];
int main() {
cin >> s;
if (strlen(s) % 2 == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < strlen(s); i++) {
if (i % 2 == 0) {
i... | #include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <string.h>
using namespace std;
char s[400005];
int main() {
cin >> s;
if (strlen(s) % 2 == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < strlen(s); i++) {
if (i % 2 == 0) {
i... | [["-", 64, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 64, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["-", 0, 9, 0, 57, 15, 339, 51, 16, 17, 79], ["+", 0, 9, 0, 57, 15, 339, 51, 16, 17, 60]] | 1 | 157 |
#define _CRT_SECURE_NO_WARNINGS
#define _USE_MATH_DEFINES
#include <algorithm>
#include <array>
#include <bitset>
#include <cctype>
#include <cmath>
#include <complex>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <functional>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#... | #define _CRT_SECURE_NO_WARNINGS
#define _USE_MATH_DEFINES
#include <algorithm>
#include <array>
#include <bitset>
#include <cctype>
#include <cmath>
#include <complex>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <functional>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["-", 0, 57, 15, 339, 51, 16, 12, 5, 0, 62], ["-", 0, 57, 15, 339, 51, 16, 12, 5, 0, 6], ["+", 15, 339, 51, 16, 31, 2, 63, 118, 17, 131], ["+", 15, 339, 51, 16, 31, 2, 63, 118, 119, 120], ["+", 15, 339, 51, 16, 31, 2, 3, 4, 0, 24], ["+", 15, 339, 51, 16, 31, 2, 3, 4, 0, 25]... | 1 | 341 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.