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 |
|---|---|---|---|---|
#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (0); i++)
using namespace std;
int main() {
cin.tie(0)->sync_with_stdio(false);
string s;
cin >> s;
int n = s.size();
bool ok = true;
if (n % 2)
ok = false;
else {
REP(i, n) {
if (i % 2) {
if (s[i] != 'i')
ok... | #include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); i++)
using namespace std;
int main() {
cin.tie(0)->sync_with_stdio(false);
string s;
cin >> s;
int n = s.size();
bool ok = true;
if (n % 2)
ok = false;
else {
REP(i, n) {
if (i % 2) {
if (s[i] != 'i')
ok... | [["-", 36, 36, 36, 36, 0, 30, 0, 112, 51, 59], ["+", 36, 36, 36, 36, 0, 30, 0, 112, 51, 59]] | 1 | 143 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String s = sc.next();
if ((s.length() % 2) != 0) {
System.out.println("NO");
return;
}
for (int i = 0; i < s.length(); i += 2) {
String a = s.substring(i,... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
String s = sc.next();
if ((s.length() % 2) != 0) {
System.out.println("No");
return;
}
for (int i = 0; i < s.length(); i += 2) {
String a = s.substring(i,... | [["-", 0, 1, 0, 492, 3, 4, 0, 5, 0, 491], ["+", 0, 1, 0, 492, 3, 4, 0, 5, 0, 491]] | 3 | 146 |
S = gets.chomp
if S.length % 2 == 1 then
print "No"
else
ans = "Yes"
for i in 1..S.length / 2 do
if S[2i-2] != "h" or S[2i-1] != "i" then
ans = "No"
end
end
print ans
end | S = gets.chomp
if S.length % 2 == 1 then
print "No"
else
ans = "Yes"
for j in 1..S.length / 2 do
if S[2 * j-2] != "h" or S[2*j-1] != "i" then
ans = "No"
end
end
print ans
end
| [["-", 0, 493, 0, 121, 75, 95, 0, 88, 374, 22], ["+", 0, 493, 0, 121, 75, 95, 0, 88, 374, 22], ["-", 31, 738, 31, 742, 0, 738, 31, 787, 0, 788], ["+", 31, 738, 31, 742, 0, 738, 31, 738, 17, 48], ["+", 31, 738, 31, 742, 0, 738, 31, 738, 12, 22], ["-", 12, 738, 31, 742, 0, 738, 31, 787, 0, 788], ["+", 12, 738, 31, 742, 0... | 4 | 70 |
#include <bits/stdc++.h>
#include <iostream>
using namespace std;
#define int long long
#define double long double
#define endl "\n"
#define pb push_back
#define PI 3.1415926535897932384626433832795l
#define F first
#define S second
#define mp make_pair
#define f(i, n) for (int i = 0; i < n; i++)
#define fastio ... | #include <bits/stdc++.h>
#include <iostream>
using namespace std;
#define int long long
#define double long double
#define endl "\n"
#define pb push_back
#define PI 3.1415926535897932384626433832795l
#define F first
#define S second
#define mp make_pair
#define f(i, n) for (int i = 0; i < n; i++)
#define fastio ... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 221 |
#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
typedef long long ll;
typedef pair<ll, ll> PLL;
typedef vector<int> VI;
typedef vector<char> VC;
typedef vector<double> VD;
typedef vector<string> VS;
typedef vector<ll> VLL;
typedef vector<PLL> VP;
const static int INF = 1000000000;
const stat... | #include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
typedef long long ll;
typedef pair<ll, ll> PLL;
typedef vector<int> VI;
typedef vector<char> VC;
typedef vector<double> VD;
typedef vector<string> VS;
typedef vector<ll> VLL;
typedef vector<PLL> VP;
const static int INF = 1000000000;
const stat... | [["-", 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 | 633 |
print('Yes' if input().replace('hi', '') else 'No') | print('No' if input().replace('hi', '') else 'Yes') | [["-", 0, 652, 3, 4, 0, 41, 0, 557, 0, 6], ["+", 0, 652, 3, 4, 0, 41, 0, 557, 0, 6]] | 5 | 24 |
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
typedef tree<int, null_type, less<int>, rb_tree_tag,
tree_order_statistics_node_update>
ordered_set;
typedef long long ll;
#define pb push_back
#define... | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
typedef tree<int, null_type, less<int>, rb_tree_tag,
tree_order_statistics_node_update>
ordered_set;
typedef long long ll;
#define pb push_back
#define... | [["+", 0, 42, 0, 23, 0, 16, 31, 16, 17, 109], ["+", 0, 42, 0, 23, 0, 16, 31, 16, 12, 13]] | 1 | 643 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int a = 0;
if (S.size() == 1) {
a++;
}
for (int i = 0; i < S.size(); i += 2) {
if (S.at(i) != 'h') {
a++;
}
}
for (int i = 1; i < S.size(); i += 2) {
if (S.at(i) != 'i') {
a++;
}
}
if (a ... | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
int a = 0;
if (S.size() % 2 == 1) {
a++;
}
for (int i = 0; i < S.size(); i += 2) {
if (S.at(i) != 'h') {
a++;
}
}
for (int i = 1; i < S.size(); i += 2) {
if (S.at(i) != 'i') {
a++;
}
}
if ... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 142 |
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)
s = readline().rstrip().decode()
if len(s) % 2 == 1:
print('No')
exit()
for i in range(len(s) // 2):
if i % 2 == 0:
if s[i] != 'h':
print('N... | import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)
s = readline().rstrip().decode()
if len(s) % 2 == 1:
print('No')
exit()
for i in range(len(s)):
if i % 2 == 0:
if s[i] != 'h':
print('No')
... | [["-", 0, 7, 12, 652, 3, 4, 0, 657, 17, 676], ["-", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 135 |
#!/usr/bin/env python3
ng = True
s = input()
for i in range(1, 5):
if s=="hi"*i: ng = False
print("YNeos"[ng::2])
| #!/usr/bin/env python3
ng = True
s = input()
for i in range(1, 6):
if s=="hi"*i: ng = False
print("YNeos"[ng::2])
| [["-", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612]] | 5 | 43 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
regex R("(hi)+");
cout << ((regex_match(S, R)) ? "YES" : "NO") << "\n";
} | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
regex R("(hi)+");
cout << ((regex_match(S, R)) ? "Yes" : "No") << "\n";
} | [["-", 31, 16, 12, 23, 0, 41, 64, 5, 0, 6], ["+", 31, 16, 12, 23, 0, 41, 64, 5, 0, 6], ["-", 31, 16, 12, 23, 0, 41, 75, 5, 0, 6], ["+", 31, 16, 12, 23, 0, 41, 75, 5, 0, 6]] | 1 | 52 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
S = regex_replace(S, regex("hi"), "A");
S.erase(unique(S.begin(), S.end()), S.end());
cout << ((S.size() == 1) ? "Yes" : "No") << "\n";
} | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
S = regex_replace(S, regex("hi"), "A");
S.erase(unique(S.begin(), S.end()), S.end());
cout << ((S == "A") ? "Yes" : "No") << "\n";
} | [["-", 15, 23, 0, 16, 31, 2, 63, 118, 17, 131], ["-", 15, 23, 0, 16, 31, 2, 63, 118, 119, 120], ["-", 15, 23, 0, 16, 31, 2, 3, 4, 0, 24], ["-", 15, 23, 0, 16, 31, 2, 3, 4, 0, 25], ["-", 12, 23, 0, 41, 15, 23, 0, 16, 12, 13], ["+", 0, 41, 15, 23, 0, 16, 12, 5, 0, 62], ["+", 0, 41, 15, 23, 0, 16, 12, 5, 0, 6]] | 1 | 89 |
S=list(input())
tmp=""
ans="No"
for s in S:
if(tmp==""):
tmp=s
else:
if(s=='i' and tmp=='h'):
ans="Yes"
tmp=''
else:
ans="No"
break
print(ans)
| S=list(input())
tmp=""
ans="No"
for s in S:
if(tmp==""):
tmp=s
ans="No"
else:
if(s=='i' and tmp=='h'):
ans="Yes"
tmp=''
else:
ans="No"
break
print(ans)
| [["+", 0, 57, 64, 196, 0, 1, 0, 662, 31, 22], ["+", 0, 57, 64, 196, 0, 1, 0, 662, 0, 32], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 654], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 64, 196, 0, 1, 0, 662, 12, 557, 0, 655]] | 5 | 71 |
require 'set'
def main
s = gets.chomp
(0..s.size/2-1).each do |i|
if s[i*2,2] != "hi"
puts "No"
return
end
end
puts "Yes"
end
main
## イディオムなど
# until s.empty? do
#
## 配列のインデックス
# s[0,6] # 0番目から6文字
# s[0..6] # 0番目から6番目まで
# s[5..-1] # 5番目から最後まで
#
## 全探索
# [0, 1]... | require 'set'
def main
s = gets.chomp
(0..(s.size+1)/2-1).each do |i|
if s[i*2,2] != "hi"
puts "No"
return
end
end
puts "Yes"
end
main
## イディオムなど
# until s.empty? do
#
## 配列のインデックス
# s[0,6] # 0番目から6文字
# s[0..6] # 0番目から6番目まで
# s[5..-1] # 5番目から最後まで
#
## 全探索
# [0... | [["+", 0, 475, 444, 738, 31, 738, 31, 739, 0, 24], ["+", 444, 738, 31, 738, 31, 739, 0, 738, 17, 72], ["+", 444, 738, 31, 738, 31, 739, 0, 738, 12, 612], ["+", 0, 475, 444, 738, 31, 738, 31, 739, 0, 25]] | 4 | 81 |
#include <algorithm>
#include <cmath>
#include <iostream>
#include <queue>
#include <string>
#include <vector>
using namespace std;
int main() {
string s;
cin >> s;
if (s.length() % 2 != 0) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.length() / 2; i++) {
if (s.substr(2 * i, 2 * i +... | #include <algorithm>
#include <cmath>
#include <iostream>
#include <queue>
#include <string>
#include <vector>
using namespace std;
int main() {
string s;
cin >> s;
if (s.length() % 2 != 0) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.length() / 2; i++) {
if (s.substr(2 * i, 2) != "... | [["-", 31, 2, 3, 4, 0, 16, 31, 16, 17, 48], ["-", 31, 2, 3, 4, 0, 16, 31, 16, 12, 22], ["-", 51, 16, 31, 2, 3, 4, 0, 16, 17, 72], ["-", 51, 16, 31, 2, 3, 4, 0, 16, 12, 13]] | 1 | 121 |
import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
Scanner sc = new Scanner(System.in);
String s = sc.next();
String[] sp = s.split("");
boolean ans = true;
if (sp.length % 2 == 0) {
for (int i = 0; i < sp.length - 1; i += 2) {
if (sp[i... | import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
Scanner sc = new Scanner(System.in);
String s = sc.next();
String[] sp = s.split("");
boolean ans = true;
if (sp.length % 2 == 0) {
for (int i = 0; i < sp.length - 1; i += 2) {
if (sp[i... | [["-", 8, 196, 0, 57, 15, 15, 0, 16, 17, 106], ["+", 8, 196, 0, 57, 15, 15, 0, 16, 17, 98]] | 3 | 172 |
#include <bits/stdc++.h>
#define ALL(a) (a).begin(), (a).end()
#define sz(x) int(x.size())
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
typedef pair<long long, long long> Pll;
typedef vector<int> vi;
typedef vector<vector<int>> vvi;
typedef vector<long long> vll;
typedef vector<vector<long long>... | #include <bits/stdc++.h>
#define ALL(a) (a).begin(), (a).end()
#define sz(x) int(x.size())
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
typedef pair<long long, long long> Pll;
typedef vector<int> vi;
typedef vector<vector<int>> vvi;
typedef vector<long long> vll;
typedef vector<vector<long long>... | [["-", 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 | 311 |
#include <iostream>
using namespace std;
string s;
int main() {
cin >> s;
if (s.length() % 2 != 0) {
cout << "NO\n";
return 0;
}
bool works = true;
for (int i = 0; i < s.length(); i += 2) {
if (s[i] != 'h' || s[i + 1] != 'i')
works = false;
}
if (works)
cout << "YES\n";
else
... | #include <iostream>
using namespace std;
string s;
int main() {
cin >> s;
if (s.length() % 2 != 0) {
cout << "No\n";
return 0;
}
bool works = true;
for (int i = 0; i < s.length(); i += 2) {
if (s[i] != 'h' || s[i + 1] != 'i')
works = false;
}
if (works)
cout << "Yes\n";
else
... | [["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["-", 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 | 114 |
#include <bits/stdc++.h>
#define rep(i, n) for (ll i = 0; i < (n); i++)
#define all(x) (x).begin(), (x).end()
using ll = long long;
using namespace std;
template <typename T> using vec = std::vector<T>;
int main() {
string S;
cin >> S;
if (S == "hi" || S == "hihi" || S == "hihihi" || S == "hihihihi" ||
S =... | #include <bits/stdc++.h>
#define rep(i, n) for (ll i = 0; i < (n); i++)
#define all(x) (x).begin(), (x).end()
using ll = long long;
using namespace std;
template <typename T> using vec = std::vector<T>;
int main() {
string S;
cin >> S;
if (S == "hi" || S == "hihi" || S == "hihihi" || S == "hihihihi" ||
S =... | [["-", 15, 339, 51, 16, 12, 16, 12, 5, 0, 6], ["+", 15, 339, 51, 16, 12, 16, 12, 5, 0, 6]] | 1 | 107 |
#include <bits/stdc++.h>
using ll = long long;
using namespace std;
#define rep(i, n) for (int i = 0, i##_len = (int)(n); i < i##_len; i++)
#define reps(i, n) for (int i = 1, i##_len = (int)(n); i <= i##_len; i++)
#define rrep(i, n) for (int i = ((int)(n)-1); i >= 0; i--)
#define rreps(i, n) for (int i = ((int)(n)); i ... | #include <bits/stdc++.h>
using ll = long long;
using namespace std;
#define rep(i, n) for (int i = 0, i##_len = (int)(n); i < i##_len; i++)
#define reps(i, n) for (int i = 1, i##_len = (int)(n); i <= i##_len; i++)
#define rrep(i, n) for (int i = ((int)(n)-1); i >= 0; i--)
#define rreps(i, n) for (int i = ((int)(n)); i ... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 358 |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef double db;
#define Check system("pause")
#define pb push_back
#define mp make_pair
#define fi first
#define se second
#define IOS \
ios::sync_with_stdio(false); ... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef double db;
#define Check system("pause")
#define pb push_back
#define mp make_pair
#define fi first
#define se second
#define IOS \
ios::sync_with_stdio(false); ... | [["-", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46]] | 1 | 139 |
S = input()
A = ["hi"*i for i in range(1,5)]
if S in A:
print("Yes")
else:
print("No") | S = input()
A = ["hi"*i for i in range(1,6)]
if S in A:
print("Yes")
else:
print("No") | [["-", 12, 658, 0, 659, 12, 652, 3, 4, 0, 612], ["+", 12, 658, 0, 659, 12, 652, 3, 4, 0, 612]] | 5 | 42 |
s = input()
possible_answers = ['hi', 'hihi', 'hihihi', 'hihihihihi']
if s in possible_answers:
print('Yes')
else:
print('No') | s = input()
possible_answers = ['hi', 'hihi', 'hihihi', 'hihihihi', 'hihihihihi']
if s in possible_answers:
print('Yes')
else:
print('No')
| [["+", 0, 1, 0, 662, 12, 634, 0, 557, 0, 6], ["+", 0, 1, 0, 662, 12, 634, 0, 557, 0, 655], ["+", 0, 656, 0, 1, 0, 662, 12, 634, 0, 21], ["+", 0, 1, 0, 662, 12, 634, 0, 557, 0, 654]] | 5 | 43 |
#!/usr/bin/env python3
import re
def main():
S = input()
if re.match(r'(?:hi)+', S):
print('Yes')
else:
print('No')
if __name__ == "__main__":
main()
| #!/usr/bin/env python3
import re
def main():
S = input()
if re.match(r'^(?:hi)+$', S):
print('Yes')
else:
print('No')
if __name__ == "__main__":
main()
| [["-", 0, 57, 15, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 57, 15, 652, 3, 4, 0, 557, 0, 6]] | 5 | 49 |
S = str(input())
ans = 'Yes'
from collections import Counter
SC = Counter(list(S))
h,i = 0,0
for a,b in SC.items():
if a == 'h':
h = b
elif a == 'i':
i = b
else:
ans = 'No'
break
if h == i:
for i in range(0,len(S)-1,2):
if S[i]+S[i+1] != 'hi':
ans = 'No'
break
print(ans) | S = str(input())
ans = 'Yes'
from collections import Counter
SC = Counter(list(S))
h,i = 0,0
for a,b in SC.items():
if a == 'h':
h = b
elif a == 'i':
i = b
else:
ans = 'No'
break
if h == i:
for i in range(0,len(S)-1,2):
if S[i]+S[i+1] != 'hi':
ans = 'No'
break
else:
ans = 'No... | [["+", 36, 36, 0, 656, 0, 57, 75, 76, 0, 95], ["+", 36, 36, 0, 656, 0, 57, 75, 76, 0, 102], ["+", 75, 76, 8, 196, 0, 1, 0, 662, 31, 22], ["+", 75, 76, 8, 196, 0, 1, 0, 662, 0, 32], ["+", 8, 196, 0, 1, 0, 662, 12, 557, 0, 654], ["+", 8, 196, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 8, 196, 0, 1, 0, 662, 12, 557, 0, 655]] | 5 | 121 |
S = input()
if S.count("hi") == len(S)//2:
print("Yes")
else:
print("No") | S = input()
if S.count("hi") == len(S)/2:
print("Yes")
else:
print("No") | [["-", 0, 656, 0, 57, 15, 666, 0, 657, 17, 676], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 85]] | 5 | 36 |
import java.util.*;
public class Main {
public static void main(String args[]) {
Scanner sn = new Scanner(System.in);
String S = sn.next();
String s = "";
int flag = 0;
for (int i = 0; i < S.length() / 2; i++) {
s += "hi";
if (s.equals("hi")) {
flag++;
System.out.print... | import java.util.*;
public class Main {
public static void main(String args[]) {
Scanner sn = new Scanner(System.in);
String S = sn.next();
String s = "";
int flag = 0;
for (int i = 0; i < S.length() / 2; i++) {
s += "hi";
if (s.equals(S)) {
flag++;
System.out.println(... | [["-", 15, 15, 0, 492, 3, 4, 0, 5, 0, 62], ["-", 15, 15, 0, 492, 3, 4, 0, 5, 0, 491], ["+", 0, 57, 15, 15, 0, 492, 3, 4, 0, 22]] | 3 | 129 |
// include
// ------------------------------------------------
#include <algorithm>
#include <bits/stdc++.h>
#include <math.h>
using namespace std;
// func
// ------------------------------------------------
int CalcSumOfDigit(int n); // 各桁の和を計算する。
int getDigit(int n); // 数字の桁数を取得する。
string upper(string str); ... | // include
// ------------------------------------------------
#include <algorithm>
#include <bits/stdc++.h>
#include <math.h>
using namespace std;
// func
// ------------------------------------------------
int CalcSumOfDigit(int n); // 各桁の和を計算する。
int getDigit(int n); // 数字の桁数を取得する。
string upper(string str); ... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 18], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 109]] | 1 | 714 |
#include <bits/stdc++.h>
using namespace std;
#define inf 100000000000000000
#define ll long long
#define pb push_back
#define f first
#define s second
#define mod 1000000007
#define fast ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL)
#define test ... | #include <bits/stdc++.h>
using namespace std;
#define inf 100000000000000000
#define ll long long
#define pb push_back
#define f first
#define s second
#define mod 1000000007
#define fast ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL)
#define test ... | [["-", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46]] | 1 | 192 |
import java.util.*;
public class Main {
public static void main(String[] args) {
Scanner stdIn = new Scanner(System.in);
String s = stdIn.next();
String hitachi = "";
for (int i = 1; i <= 5; i++) {
hitachi += "hi";
if (hitachi == s) {
System.out.println("Yes");
return;... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner stdIn = new Scanner(System.in);
String s = stdIn.next();
String hitachi = "";
for (int i = 1; i <= 5; i++) {
hitachi += "hi";
if (hitachi.equals(s)) {
System.out.println("Yes");
... | [["-", 36, 36, 0, 493, 0, 454, 0, 525, 0, 48], ["+", 36, 36, 0, 493, 0, 454, 0, 522, 141, 22], ["-", 8, 196, 0, 57, 15, 15, 0, 16, 17, 60], ["+", 8, 196, 0, 57, 15, 15, 0, 492, 0, 131], ["+", 8, 196, 0, 57, 15, 15, 0, 492, 141, 22], ["+", 0, 57, 15, 15, 0, 492, 3, 4, 0, 24], ["+", 0, 57, 15, 15, 0, 492, 3, 4, 0, 25]] | 3 | 104 |
s = gets.chomp
puts ("hi" * s.size / 2 == s)? "Yes" : "No" | s = gets.chomp
puts ("hi" * (s.size / 2) == s)? "Yes" : "No" | [["+", 15, 739, 0, 738, 31, 738, 12, 739, 0, 24], ["+", 15, 739, 0, 738, 31, 738, 12, 739, 0, 25]] | 4 | 27 |
str = gets
len = str.length
ans = 0
key = 0
if len%2 == 1
ans = 1
else
len.times do |i|
if key == 0
if str[i] == "h"
key = 1
else
ans = 1
break
end
else
if str[i] == "i"
key = 0
else
ans = 1
break
end
end
end
end
if ans == 0
puts "Yes"
else
puts "No"
end | str = gets.chomp
len = str.length
ans = 0
key = 0
if len%2 == 1
ans = 1
else
len.times do |i|
if key == 0
if str[i] == "h"
key = 1
else
ans = 1
break
end
else
if str[i] == "i"
key = 0
else
ans = 1
break
end
end
end
end
if ans == 0
puts "Yes"
else
puts "No"
end | [["+", 36, 36, 0, 493, 0, 662, 12, 652, 17, 131], ["+", 36, 36, 0, 493, 0, 662, 12, 652, 735, 22]] | 4 | 89 |
#include <algorithm>
#include <assert.h>
#include <bitset>
#include <climits>
#include <cmath>
#include <cstring>
#include <deque>
#include <ext/pb_ds/assoc_container.hpp>
#include <ios>
#include <iostream>
#include <iterator>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <... | #include <algorithm>
#include <assert.h>
#include <bitset>
#include <climits>
#include <cmath>
#include <cstring>
#include <deque>
#include <ext/pb_ds/assoc_container.hpp>
#include <ios>
#include <iostream>
#include <iterator>
#include <map>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <... | [["-", 8, 9, 0, 7, 15, 16, 12, 16, 17, 33], ["-", 8, 9, 0, 7, 15, 16, 12, 16, 12, 13]] | 1 | 162 |
s = gets.chomp
puts s.match(/.[hi]/) ? 'Yes' : 'No' | s = gets.chomp
puts s.match(/^(hi)+$/) ? 'Yes' : 'No' | [["-", 0, 754, 15, 652, 3, 4, 0, 575, 0, 6], ["+", 0, 754, 15, 652, 3, 4, 0, 575, 0, 6]] | 4 | 22 |
#include <algorithm> // min, max, swap, sort, reverse, lower_bound, upper_bound
#include <bitset> // bitset
#include <cctype> // isupper, islower, isdigit, toupper, tolower
#include <cstdint> // int64_t, int*_t
#include <cstdio> // printf
#include <deque> // deque
#include <iomanip>
#include <iostream>
#... | #include <algorithm> // min, max, swap, sort, reverse, lower_bound, upper_bound
#include <bitset> // bitset
#include <cctype> // isupper, islower, isdigit, toupper, tolower
#include <cstdint> // int64_t, int*_t
#include <cstdio> // printf
#include <deque> // deque
#include <iomanip>
#include <iostream>
#... | [["-", 51, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["-", 51, 16, 31, 16, 31, 23, 0, 16, 12, 13], ["-", 3, 4, 0, 16, 31, 23, 0, 16, 17, 33], ["-", 3, 4, 0, 16, 31, 23, 0, 16, 12, 13]] | 1 | 179 |
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
String s = input.next();
boolean valid = true;
if (s.length() % 2 == 1)
valid = false;
else {
for (int i = 0; i < s.length() - 1; i += 2) {
if (s.cha... | import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
String s = input.next();
boolean valid = true;
if (s.length() % 2 == 1)
valid = false;
else {
for (int i = 0; i < s.length() - 1; i += 2) {
if (s.cha... | [["-", 8, 196, 0, 57, 15, 15, 0, 16, 17, 98], ["+", 8, 196, 0, 57, 15, 15, 0, 16, 17, 106]] | 3 | 138 |
s=input().relpace("hi","")
if len(s)==0:
print("Yes")
else:
print("No")
| s=input().replace("hi","")
if len(s)==0:
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 | 37 |
S = input()
hi = S.replace('hi', '')
if hi == "":
print("yes")
else:
print("No") | S = input()
hi = S.replace('hi', '')
if hi == "":
print("Yes")
else:
print("No") | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 38 |
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
string S;
cin >> S;
bool A = S == "hi";
bool B = S == "hihi";
bool C = S == "hihihih";
bool D = S == "hihihihi";
bool E = S == "hihihihihi";
if (A || B || C || D || E) {
cout << "Yes" << endl;
} else {
cout << "... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
string S;
cin >> S;
bool A = S == "hi";
bool B = S == "hihi";
bool C = S == "hihihi";
bool D = S == "hihihihi";
bool E = S == "hihihihihi";
if (A || B || C || D || E) {
cout << "Yes" << endl;
} else {
cout << "N... | [["-", 0, 43, 49, 50, 51, 16, 12, 5, 0, 6], ["+", 0, 43, 49, 50, 51, 16, 12, 5, 0, 6]] | 1 | 102 |
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_... | import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_... | [["-", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612], ["+", 0, 656, 0, 7, 12, 652, 3, 4, 0, 612]] | 5 | 233 |
S = input()
S.replace("hi", "")
if S == "":
print("No")
else:
print("Yes") | S = input()
if S.replace("hi", "") == "":
print("Yes")
else:
print("No") | [["+", 36, 36, 36, 36, 0, 656, 0, 57, 0, 121], ["-", 36, 36, 36, 36, 0, 656, 0, 57, 0, 121], ["-", 36, 36, 0, 656, 0, 57, 15, 666, 0, 22], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 36 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string u;
char h, i;
int len, deff = 0;
cin >> u;
h = 'h';
i = 'i';
len = u.length();
if (len % 2 == 1) {
deff = 1;
}
for (int i = 0; i < len; ++i) {
if (i % 2 == 0) {
if (u[i] != h) {
deff = 1;
}
} else {
... | #include <bits/stdc++.h>
using namespace std;
int main() {
string u;
char h, j;
int len, deff = 0;
cin >> u;
h = 'h';
j = 'i';
len = u.length();
if (len % 2 == 1) {
deff = 1;
}
for (int i = 0; i < len; ++i) {
if (i % 2 == 0) {
if (u[i] != h) {
deff = 1;
}
} else {
... | [["-", 0, 30, 0, 14, 8, 9, 0, 43, 49, 22], ["+", 0, 30, 0, 14, 8, 9, 0, 43, 49, 22], ["-", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["-", 0, 9, 0, 57, 15, 339, 51, 16, 12, 22], ["+", 0, 9, 0, 57, 15, 339, 51, 16, 12, 22]] | 1 | 147 |
S = str(input())
S_size = len(S)
hi_size = S.count('hi')
if S_size == hi_size * 2:
print('yes')
else:
print('no') | S = str(input())
S_size = len(S)
hi_size = S.count('hi')
if S_size == hi_size * 2:
print('Yes')
else:
print('No') | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 45 |
S=input()
for i in range(5):
if S=="hi" *i:
print("Yes")
exit()
print("No")
| S=input()
for i in range(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]] | 5 | 37 |
#include <cstring>
#include <iostream>
using namespace std;
char S[15];
int main() {
cin >> S;
if (strlen(S) % 2 != 0) {
cout << "No\n";
return 0;
}
for (int i = 0; i < strlen(S); i += 2)
if ((!S[i] == 'h' && S[i + 1] == 'i')) {
cout << "No\n";
return 0;
}
cout << "Yes\n";
return... | #include <cstring>
#include <iostream>
using namespace std;
char S[15];
int main() {
cin >> S;
if (strlen(S) % 2 != 0) {
cout << "No\n";
return 0;
}
for (int i = 0; i < strlen(S); i += 2)
if (!(S[i] == 'h' && S[i + 1] == 'i')) {
cout << "No\n";
return 0;
}
cout << "Yes\n";
return... | [["-", 0, 7, 8, 57, 15, 339, 51, 23, 0, 24], ["+", 8, 57, 15, 339, 51, 91, 28, 23, 0, 24]] | 1 | 112 |
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (ll i = 0; i < n; i++)
using ll = long long;
using P = pair<ll, ll>;
int main() {
string s;
cin >> s;
string hitachi = " ";
rep(i, 5) {
hitachi += "hi";
if (hitachi == s) {
cout << "Yes" << endl;
return 0;
}
}
cout ... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (ll i = 0; i < n; i++)
using ll = long long;
using P = pair<ll, ll>;
int main() {
string s;
cin >> s;
string hitachi = "";
rep(i, 5) {
hitachi += "hi";
if (hitachi == s) {
cout << "Yes" << endl;
return 0;
}
}
cout <... | [["-", 8, 9, 0, 43, 49, 50, 51, 5, 0, 6]] | 1 | 92 |
z = input()
if z=='hi' or z=='hihi' or z=='hihihi' or z=='hihihihi' or z=='hihihihihi':
return "Yes"
else:
return "No" | z = input()
if z=='hi' or z=='hihi' or z=='hihihi' or z=='hihihihi' or z=='hihihihihi':
print("Yes")
else:
print("No") | [["-", 0, 656, 0, 57, 64, 196, 0, 37, 0, 38], ["+", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 64, 196, 0, 1, 0, 652, 3, 4, 0, 25], ["-", 0, 57, 75, 76, 8, 196, 0, 37, 0, 38], ["+", 75, 76, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 8, 196... | 5 | 46 |
#include <bits/stdc++.h>
using namespace std;
#define SZ(x) ((int)(x).size())
typedef long long ll;
int main(void) {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
string s;
cin >> s;
if (SZ(s) % 2)
cout << "NO" << endl;
else {
for (int i(0); i < SZ(s); i += 2)
if (s[i] != 'h... | #include <bits/stdc++.h>
using namespace std;
#define SZ(x) ((int)(x).size())
typedef long long ll;
int main(void) {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
string s;
cin >> s;
if (SZ(s) % 2)
cout << "No" << endl;
else {
for (int i(0); i < SZ(s); i += 2)
if (s[i] != 'h... | [["-", 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 | 134 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
bool flg = true;
if (s.size() % 2 != 0)
flg = false;
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 1) {
if (s[i] != 'h')
flg = false;
} else {
if (s[i] != 'i')
flg = false;
}
}
i... | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
bool flg = true;
if (s.size() % 2 != 0)
flg = false;
for (int i = 1; i <= s.size(); i++) {
if (i % 2 == 1) {
if (s[i - 1] != 'h')
flg = false;
} else {
if (s[i - 1] != 'i')
flg = false;
... | [["-", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["+", 8, 9, 0, 7, 10, 43, 49, 50, 51, 13], ["-", 0, 14, 8, 9, 0, 7, 15, 16, 17, 18], ["+", 0, 14, 8, 9, 0, 7, 15, 16, 17, 19], ["+", 51, 16, 31, 69, 341, 342, 0, 16, 17, 33], ["+", 51, 16, 31, 69, 341, 342, 0, 16, 12, 13]] | 1 | 127 |
#include <bits/stdc++.h>
#define REP(i, n) for (long long i = 0; i < (long long)n; i++)
#define _GLIBCXX_DEBUG
using namespace std;
using ll = long long;
using Pi = pair<int, int>;
using Pl = pair<ll, ll>;
using Vecl = vector<ll>;
using Graph = vector<vector<int>>;
int main() {
cin.tie(0);
ios::sync_with_stdio(fal... | #include <bits/stdc++.h>
#define REP(i, n) for (long long i = 0; i < (long long)n; i++)
#define _GLIBCXX_DEBUG
using namespace std;
using ll = long long;
using Pi = pair<int, int>;
using Pl = pair<ll, ll>;
using Vecl = vector<ll>;
using Graph = vector<vector<int>>;
int main() {
cin.tie(0);
ios::sync_with_stdio(fal... | [["-", 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 | 204 |
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')
| li = list(input())
n = len(li)
for i in range(0, n, 2):
if li[i] == 'h' and li[i + 1] == 'i' and n % 2 == 0:
pass
else:
print('No')
exit()
print('Yes')
| [["-", 0, 7, 12, 652, 3, 4, 0, 652, 63, 22], ["-", 12, 652, 3, 4, 0, 652, 3, 4, 0, 24], ["-", 3, 4, 0, 652, 3, 4, 0, 657, 17, 85], ["-", 3, 4, 0, 652, 3, 4, 0, 657, 12, 612], ["-", 12, 652, 3, 4, 0, 652, 3, 4, 0, 25]] | 5 | 76 |
//=========================================c++
/* ===========================================
// 20.03.19
//
//
=========================================== */
/* ===========================================
content
=========================================== */
#include <bits/stdc++.h>
using namespace std;
typedef lon... | //=========================================c++
/* ===========================================
// 20.04.03 日立製作所 社会システム事業部 プログラミングコンテスト2020 - A.
Hitachi String
//
//
=========================================== */
/* ===========================================
content
=========================================== */
#inc... | [["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]] | 1 | 204 |
S = str(input())
S.replace("hi", "")
if S == "":
print("Yes")
else:
print("No") | S = str(input())
S1 = S.replace("hi", "")
if S1 == "":
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, 57, 15, 666, 0, 22], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 0, 22]] | 5 | 39 |
s = input()
ans = "No"
for i in range(5):
if s == "hi" * i:
ans = "Yes"
print(ans) | s = input()
ans = "No"
for i in range(1, 6):
if s == "hi" * i:
ans = "Yes"
print(ans) | [["-", 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 | 36 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
string X = "";
for (int i = 0; i < 5; i++) {
X = X + "hi";
if (X == S) {
cout << "Yes" << endl;
break;
}
cout << "No" << endl;
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
string X = "";
for (int i = 0; i < 5; i++) {
X = X + "hi";
if (X == S) {
cout << "Yes" << endl;
return 0;
}
}
cout << "No" << endl;
}
| [["-", 8, 9, 0, 57, 64, 9, 0, 93, 0, 94], ["+", 8, 9, 0, 57, 64, 9, 0, 37, 0, 38], ["+", 8, 9, 0, 57, 64, 9, 0, 37, 0, 13], ["+", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46]] | 1 | 75 |
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") | s = str(input())
#print(s[0]+s[1])
hitati = "hi"
for i in range(5):
if s == hitati:
print("Yes")
exit()
else:
hitati += "hi"
print("No") | [["-", 75, 76, 8, 196, 0, 1, 0, 677, 12, 22], ["+", 8, 196, 0, 1, 0, 677, 12, 557, 0, 654], ["+", 8, 196, 0, 1, 0, 677, 12, 557, 0, 6], ["+", 8, 196, 0, 1, 0, 677, 12, 557, 0, 655]] | 5 | 47 |
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')
| import sys
input = sys.stdin.readline
sys.setrecursionlimit(10000000)
from collections import defaultdict
from bisect import *
mod = 10**9+7
S = input()[:-1]
for i in range(5):
if 'hi' * (i+1) == S:
print('Yes')
exit()
print('No')
| [["+", 0, 656, 0, 1, 0, 662, 12, 206, 0, 70], ["+", 0, 1, 0, 662, 12, 206, 206, 663, 0, 102], ["+", 0, 662, 12, 206, 206, 663, 0, 664, 17, 33], ["+", 0, 662, 12, 206, 206, 663, 0, 664, 28, 612], ["+", 0, 656, 0, 1, 0, 662, 12, 206, 0, 73]] | 5 | 71 |
#include <iostream>
#include <string>
int main() {
std::string hitachi;
std::cin >> hitachi;
std::string type_hitachi;
for (int i = 0; i < hitachi.size(); ++i) {
type_hitachi += "hi";
}
if (hitachi == type_hitachi) {
std::cout << "Yes" << std::endl;
} else {
std::cout << "No" << std::endl;
... | #include <iostream>
#include <string>
int main() {
std::string hitachi;
std::cin >> hitachi;
std::string type_hitachi;
for (int i = 0; i < hitachi.size() / 2; ++i) {
type_hitachi += "hi";
}
if (hitachi == type_hitachi) {
std::cout << "Yes" << std::endl;
} else {
std::cout << "No" << std::endl... | [["+", 8, 9, 0, 7, 15, 16, 12, 16, 17, 85], ["+", 8, 9, 0, 7, 15, 16, 12, 16, 12, 13]] | 1 | 90 |
#include <bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
string s;
cin >> s;
bool ans = true;
if (s.size() == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 0)
ans = s.at(i) == 'h';
if (i % 2 == 1)
ans = s.at(i) ==... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
string s;
cin >> s;
bool ans = true;
if (s.size() % 2 == 1) {
cout << "No" << endl;
return 0;
}
for (int i = 0; i < s.size(); i++) {
if (i % 2 == 0)
ans = s.at(i) == 'h';
if (i % 2 == 1)
ans = s.at(i... | [["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13]] | 1 | 141 |
s = input().split('i')
h = s[:len(s)-1]
space = s[len(s)-1]
for j in h:
if j =='h' and space == '':
ans = 'Yes'
else:
ans = 'No'
print(ans) | 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:
ans = 'No'
break
print(ans)
| [["+", 36, 36, 0, 656, 0, 1, 0, 662, 31, 22], ["+", 36, 36, 0, 656, 0, 1, 0, 662, 0, 32], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 654], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 655], ["+", 0, 57, 75, 76, 8, 196, 0, 93, 0, 94]] | 5 | 68 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
if ((int)s.size() % 2 != 0) {
cout << "NO";
} else {
for (int i = 0; i < s.size(); i += 2)
if (s[i] != 'h' || s[i + 1] != 'i') {
cout << "No";
return 0;
}
cout << "Yes";
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
if ((int)s.size() % 2 != 0) {
cout << "No";
} else {
for (int i = 0; i < s.size(); i += 2)
if (s[i] != 'h' || s[i + 1] != 'i') {
cout << "No";
return 0;
}
cout << "Yes";
}
}
| [["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 103 |
#include <stdio.h>
#include <string.h>
int main() {
char a[100];
scanf("%s", a);
if (strlen(a) % 2)
printf("No");
else {
for (int i = 0; a[i] != '\0'; i += 2) {
if (a[i] == 'h' && a[i + 1] == 'i')
;
else {
printf("No");
return 0;
}
}
}
printf("Yes");
r... | #include <stdio.h>
#include <string.h>
int main() {
char a[100];
scanf("%s", a);
if (strlen(a) % 2)
printf("No");
else {
for (int i = 0; a[i] != '\0'; i += 2) {
if (a[i] == 'h' && a[i + 1] == 'i')
;
else {
printf("No");
return 0;
}
}
printf("Yes");
}
... | [["-", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46]] | 1 | 112 |
#include <cstdio>
#include <iostream>
using namespace std;
string s;
int main() {
cin >> s;
if ((int)s.size() % 2)
return puts("No") * 0;
for (int i = 0; s[i]; i++) {
if (i & 1 == 0 && s[i] != 'h' || i & 1 == 1 && s[i] != 'i')
return puts("No") * 0;
}
return puts("Yes") * 0;
} | #include <cstdio>
#include <iostream>
using namespace std;
string s;
int main() {
cin >> s;
if ((int)s.size() % 2)
return puts("No") * 0;
for (int i = 0; s[i]; i++) {
if (i % 2 == 0 && s[i] != 'h' || i % 2 == 1 && s[i] != 'i')
return puts("No") * 0;
}
return puts("Yes") * 0;
} | [["-", 15, 339, 51, 16, 31, 16, 31, 16, 17, 67], ["-", 51, 16, 31, 16, 31, 16, 12, 16, 31, 13], ["+", 51, 16, 31, 16, 31, 16, 31, 16, 17, 109], ["+", 51, 16, 31, 16, 31, 16, 31, 16, 12, 13], ["-", 15, 339, 51, 16, 12, 16, 31, 16, 17, 67], ["-", 51, 16, 12, 16, 31, 16, 12, 16, 31, 13], ["+", 51, 16, 12, 16, 31, 16, 31, ... | 1 | 113 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
bool ans = true;
if (s.length() < 2) {
ans = false;
} else {
for (int i = 0; i < s.length(); i++) {
if (i % 2 == 0)
if (s[i] != 'h') {
ans = false;
break;
}
if (i % 2 == 1)
... | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
bool ans = true;
if (s.length() % 2 != 0) {
ans = false;
} else {
for (int i = 0; i < s.length(); i++) {
if (i % 2 == 0)
if (s[i] != 'h') {
ans = false;
break;
}
if (i % 2 =... | [["-", 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 | 137 |
#include <iostream>
#include <regex>
#include <string>
using namespace std;
int main() {
string input;
cin >> input;
cout << (regex_search(input, regex("(hi)+")) ? "Yes" : "No") << endl;
}
| #include <iostream>
#include <regex>
#include <string>
using namespace std;
int main() {
string input;
cin >> input;
cout << (regex_match(input, regex("(hi)+")) ? "Yes" : "No") << endl;
}
| [["-", 31, 16, 12, 23, 0, 41, 15, 2, 63, 22], ["+", 31, 16, 12, 23, 0, 41, 15, 2, 63, 22]] | 1 | 49 |
#include <iostream>
#include <regex>
#include <string>
bool check(const std::string &buff) {
return std::regex_match(buff, std::regex("(hi)+"));
}
void process() {
auto buff = std::string{};
std::getline(std::cin, buff);
std::cout << (check(buff) ? "YES" : "NO") << std::endl;
}
int main() { process(); } | #include <iostream>
#include <regex>
#include <string>
bool check(const std::string &buff) {
return std::regex_match(buff, std::regex("(hi)+"));
}
void process() {
auto buff = std::string{};
std::getline(std::cin, buff);
std::cout << (check(buff) ? "Yes" : "No") << std::endl;
}
int main() { process(); } | [["-", 31, 16, 12, 23, 0, 41, 64, 5, 0, 6], ["+", 31, 16, 12, 23, 0, 41, 64, 5, 0, 6], ["-", 31, 16, 12, 23, 0, 41, 75, 5, 0, 6], ["+", 31, 16, 12, 23, 0, 41, 75, 5, 0, 6]] | 1 | 94 |
S=input()
if S.count("hi")*2==len(s):
print("Yes")
else:
print("No") | S=input()
if S.count("hi")*2==len(S):
print("Yes")
else:
print("No") | [["-", 0, 57, 15, 666, 0, 652, 3, 4, 0, 22], ["+", 0, 57, 15, 666, 0, 652, 3, 4, 0, 22]] | 5 | 36 |
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') | 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 == 1 or len(S)%2 == 1:
print('No')
else:
print('Yes') | [["-", 0, 656, 0, 57, 15, 679, 31, 666, 0, 612], ["+", 0, 656, 0, 57, 15, 679, 31, 666, 0, 612]] | 5 | 85 |
#define _USE_NATH_DEFINES
#include <algorithm>
#include <bitset>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdio>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <limits>
#include <list>
#include <map>
#include <numer... | #define _USE_NATH_DEFINES
#include <algorithm>
#include <bitset>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdio>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <limits>
#include <list>
#include <map>
#include <numer... | [["+", 8, 9, 0, 9, 0, 1, 0, 11, 31, 22], ["+", 8, 9, 0, 9, 0, 1, 0, 11, 17, 107], ["+", 0, 9, 0, 1, 0, 11, 12, 5, 0, 62], ["+", 0, 9, 0, 1, 0, 11, 12, 5, 0, 6], ["+", 0, 14, 8, 9, 0, 9, 0, 1, 0, 35]] | 1 | 250 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string N;
int count = 0;
cin >> N;
if (N == "hi")
count++;
if (N == "hihi")
count++;
if (N == "hihihi")
count++;
if (N == "hihihihi")
count++;
if (N == "hihihihihi")
count++;
if (count >= 1)
cout << "YES" << endl;
e... | #include <bits/stdc++.h>
using namespace std;
int main() {
string N;
int count = 0;
cin >> N;
if (N == "hi")
count++;
if (N == "hihi")
count++;
if (N == "hihihi")
count++;
if (N == "hihihihi")
count++;
if (N == "hihihihihi")
count++;
if (count >= 1)
cout << "Yes" << endl;
e... | [["-", 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 | 103 |
// #pragma GCC optimize("Ofast")
// #pragma GCC optimize("no-stack-protector")
// #pragma GCC optimize("unroll-loops")
// #pragma GCC optimize("fast-math")
// #pragma GCC target("sse,sse2,sse3,ssse3,popcnt,abm,mmx,tune=native")
#include <algorithm>
#include <bitset>
#include <cmath>
#include <cstdio>
#include <cstring... | // #pragma GCC optimize("Ofast")
// #pragma GCC optimize("no-stack-protector")
// #pragma GCC optimize("unroll-loops")
// #pragma GCC optimize("fast-math")
// #pragma GCC target("sse,sse2,sse3,ssse3,popcnt,abm,mmx,tune=native")
#include <algorithm>
#include <bitset>
#include <cmath>
#include <cstdio>
#include <cstring... | [["-", 0, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["+", 0, 9, 0, 57, 15, 339, 51, 16, 17, 79]] | 1 | 271 |
#include <iostream>
#include <string>
using namespace std;
int main() {
string str;
cin >> str;
bool hFlag = false;
bool iFlag = false;
int count = 0;
for (int i = 0; i < str.length(); i++) {
if (count == 0 && str[i] == 'h') {
hFlag = true;
count++;
} else if (count == 1 && str[i] == '... | #include <iostream>
#include <string>
using namespace std;
int main() {
string str;
cin >> str;
bool hFlag = false;
bool iFlag = false;
int count = 0;
for (int i = 0; i < str.length(); i++) {
if (count == 0 && str[i] == 'h') {
hFlag = true;
iFlag = false;
count++;
} else if (coun... | [["+", 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 | 149 |
s = input()
if len(s) // 2 ==1:
print('No')
exit()
if s == "hi"* (len(s) // 2):
print('Yes')
else:
print('No') |
s = input()
if len(s) % 2 ==1:
print('No')
exit()
if s == "hi"* (len(s) // 2):
print('Yes')
else:
print('No') | [["-", 0, 656, 0, 57, 15, 666, 0, 657, 17, 676], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 109]] | 5 | 54 |
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(void) {
char s[100];
scanf("%s", s);
for (int i = 0; s[i] != '\0'; i++) {
if (i % 2 == 0) {
if (s[i] != 'h') {
printf("No\n");
return 0;
}
} else {
if (s[i] != 'i') {
printf("No\n");
retu... | #include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(void) {
char s[100];
scanf("%s", s);
for (int i = 0; s[i] != '\0'; i++) {
if (i % 2 == 0) {
if (s[i] != 'h') {
printf("No\n");
return 0;
}
} else {
if (s[i] != 'i') {
printf("No\n");
retu... | [["+", 15, 23, 0, 16, 31, 69, 71, 16, 17, 33], ["+", 15, 23, 0, 16, 31, 69, 71, 16, 12, 13]] | 0 | 178 |
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")
| 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 == 0:
print("Yes")
else:
print("No")
| [["-", 0, 656, 0, 57, 15, 679, 12, 666, 0, 612], ["+", 0, 656, 0, 57, 15, 679, 12, 666, 0, 612]] | 5 | 88 |
import re
S=input()
pattern = '(hi)+'
result = re.match(pattern, S)
if result:
print('Yes')
else:
print('No') | import re
S=input()
pattern = '^(hi)+$'
result = re.match(pattern, S)
if result:
print('Yes')
else:
print('No') | [["-", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6]] | 5 | 39 |
#include "bits/stdc++.h"
using namespace std;
using ll = long long;
#define rep(i, begin, n) for (int i = begin; i < n; i++)
#define repe(i, begin, n) for (int i = begin; i <= n; i++)
#define repr(i, begin, n) for (int i = begin; i > begin - n; i--)
#define repre(i, begin, end) for (int i = begin; i >= end; i--)
templ... | #include "bits/stdc++.h"
using namespace std;
using ll = long long;
#define rep(i, begin, n) for (int i = begin; i < n; i++)
#define repe(i, begin, n) for (int i = begin; i <= n; i++)
#define repr(i, begin, n) for (int i = begin; i > begin - n; i--)
#define repre(i, begin, end) for (int i = begin; i >= end; i--)
templ... | [["-", 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 | 237 |
s = input()
s.replace("hi", "")
print("Yes" if s=="" else "No") | s = input()
s=s.replace("hi", "")
print("Yes" if s=="" else "No") | [["+", 36, 36, 0, 656, 0, 1, 0, 662, 0, 32], ["+", 0, 1, 0, 662, 12, 652, 63, 319, 500, 22]] | 5 | 31 |
#include <iostream>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
if (s.size() % 2) {
cout << "No";
} else {
for (int i = 0; i < s.size(); i += 2) {
if (s[i] != 'h' || s[i + 1] != 'i') {
cout << "No";
return 0;
}
}
}
cout << "Yes";
return... | #include <iostream>
#include <string>
using namespace std;
int main() {
string s;
cin >> s;
if (s.size() % 2) {
cout << "No";
} else {
for (int i = 0; i < s.size(); i += 2) {
if (s[i] != 'h' || s[i + 1] != 'i') {
cout << "No";
return 0;
}
}
cout << "Yes";
}
retu... | [["-", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46], ["+", 8, 9, 0, 57, 75, 76, 0, 9, 0, 46]] | 1 | 105 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
bool flag = true;
if (S.size() > 10) {
cout << "No";
return 0;
}
for (int i = 0; i < S.size(); i += 2) {
if (S.at(i) != 'h' || S.at(i + 1) != 'i')
flag = false;
}
if (flag)
cout << "Yes";
else
c... | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
bool flag = true;
if (S.size() % 2 != 0) {
cout << "No";
return 0;
}
for (int i = 0; i < S.size(); i += 2) {
if (S.at(i) != 'h' || S.at(i + 1) != 'i')
flag = false;
}
if (flag)
cout << "Yes";
else
... | [["-", 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, 79], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 113 |
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") | 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 flg == False:
print("No")
else:
print("Yes") | [["-", 75, 76, 8, 196, 0, 57, 15, 666, 0, 22], ["+", 75, 76, 8, 196, 0, 57, 15, 666, 0, 22], ["-", 8, 196, 0, 57, 15, 666, 0, 557, 0, 654], ["-", 8, 196, 0, 57, 15, 666, 0, 557, 0, 655], ["+", 75, 76, 8, 196, 0, 57, 15, 666, 0, 147]] | 5 | 86 |
S=list(input())
while len(S)>0:
if S[0] == 'h' and S[1] == 'i':
S.remove('h')
S.remove('i')
else:
break
if len(S) == 0:
print('Yes')
else:
print('No')
| S=list(input())
while len(S)>1:
if S[0] == 'h' and S[1] == 'i':
S.remove('h')
S.remove('i')
else:
break
if len(S) == 0:
print('Yes')
else:
print('No')
| [["-", 36, 36, 0, 656, 0, 52, 15, 666, 0, 612], ["+", 36, 36, 0, 656, 0, 52, 15, 666, 0, 612]] | 5 | 76 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
int f = 0;
if (s.size() % 2) {
cout << "No";
return 0;
} else {
for (int i = 0; i < s.size(); i += 2) {
if (s[i] != 'h' || s[i + 1] != 'i') {
f = 1;
cout << "No";
}
}
}
if (f == 0)
... | #include <bits/stdc++.h>
using namespace std;
int main() {
string s;
cin >> s;
int f = 0;
if (s.size() % 2) {
cout << "No";
return 0;
} else {
for (int i = 0; i < s.size(); i += 2) {
if (s[i] != 'h' || s[i + 1] != 'i') {
f = 1;
cout << "No";
break;
}
}
}
... | [["+", 8, 9, 0, 57, 64, 9, 0, 93, 0, 94], ["+", 8, 9, 0, 57, 64, 9, 0, 93, 0, 35]] | 1 | 115 |
import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) throws IOException {
FastReader scan = new FastReader();
// PrintWriter out = new PrintWriter(new BufferedWriter(new
// FileWriter("taming.out")));
PrintWriter out =
new PrintWriter(new BufferedWr... | import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) throws IOException {
FastReader scan = new FastReader();
// PrintWriter out = new PrintWriter(new BufferedWriter(new
// FileWriter("taming.out")));
PrintWriter out =
new PrintWriter(new BufferedWr... | [["-", 15, 15, 0, 492, 3, 4, 0, 5, 0, 491], ["+", 15, 15, 0, 492, 3, 4, 0, 5, 0, 491]] | 3 | 612 |
S = str(input())
if S == 'hi' or S == 'hihi' or S == 'hihihi' or S == 'hihihihi' or S == 'hihihihihihi':
print ('Yes')
else:
print ('No') | S = str(input())
if S == 'hi' or S == 'hihi' or S == 'hihihi' or S == 'hihihihi' or S == 'hihihihihi':
print ('Yes')
else:
print ('No')
| [["-", 0, 57, 15, 679, 12, 666, 0, 557, 0, 6], ["+", 0, 57, 15, 679, 12, 666, 0, 557, 0, 6]] | 5 | 53 |
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; i++)
#define PI 3.14159265359
#define INF 1000100100
typedef long long ll;
using namespace std;
int main() {
string s;
cin >> s;
if (s.length() % 2 == 1)
cout << "No" << endl;
else {
for (int i = 0; i < s.length(); i = i + 2) {
if ... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; i++)
#define PI 3.14159265359
#define INF 1000100100
typedef long long ll;
using namespace std;
int main() {
string s;
cin >> s;
if (s.length() % 2 == 1)
cout << "No" << endl;
else {
for (int i = 0; i < s.length(); i = i + 2) {
if ... | [["-", 8, 9, 0, 57, 15, 339, 51, 11, 17, 32], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60]] | 1 | 141 |
#include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
bool flg = true;
if (S.size() % 2 != 0) {
flg = false;
cout << "No" << endl;
return 0;
}
for (int i = 0; i < S.size(); i++) {
if (i & 2 == 0) {
if (S[i] != 'h')
flg = false;
} else {
if (S... | #include <bits/stdc++.h>
using namespace std;
int main() {
string S;
cin >> S;
bool flg = true;
if (S.size() % 2 != 0) {
flg = false;
cout << "No" << endl;
return 0;
}
for (int i = 0; i < S.size(); i++) {
if (i % 2 == 0) {
if (S[i] != 'h')
flg = false;
} else {
if (S... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 67], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 109]] | 1 | 140 |
#include <bits/stdc++.h>
using namespace std;
void solve() {
string s;
cin >> s;
if (s.length() == 0) {
cout << "No" << endl;
return;
}
for (int i = 0; i < s.length(); i++) {
if (i % 2 == 0 && s[i] != 'h' || i % 2 == 1 && s[i] != 'i') {
cout << "No" << endl;
return;
}
}
cout <... | #include <bits/stdc++.h>
using namespace std;
void solve() {
string s;
cin >> s;
if (s.length() % 2) {
cout << "No" << endl;
return;
}
for (int i = 0; i < s.length(); i++) {
if (i % 2 == 0 && s[i] != 'h' || i % 2 == 1 && s[i] != 'i') {
cout << "No" << endl;
return;
}
}
cout <<... | [["-", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 109], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13]] | 1 | 125 |
s=str(input())
a=len(s)
b=[hi,hihi,hihihi,hihihihi,hihihihihi]
if a%2!=0:
print('No')
elif s in b:
print('Yes')
else:
print('No')
| s=str(input())
a=len(s)
b=['hi','hihi','hihihi','hihihihi','hihihihihi']
if a%2!=0:
print('No')
elif s in b:
print('Yes')
else:
print('No')
| [["+", 0, 1, 0, 662, 12, 634, 0, 557, 0, 654], ["+", 0, 1, 0, 662, 12, 634, 0, 557, 0, 655]] | 5 | 59 |
#include <bits/stdc++.h>
#define forn(x, n) for (int x = 0; x < n; x++)
#define forr(x, n) for (int x = n; x >= 0; x--)
#define fore(x, a, b, c) for (int x = a; x <= b; x += c)
#define forre(x, a, b, c) for (int x = a; x >= b; x -= c)
#define clr cin.ignore(numeric_limits<streamsize>::max(), '\n')
#define all(container... | #include <bits/stdc++.h>
#define forn(x, n) for (int x = 0; x < n; x++)
#define forr(x, n) for (int x = n; x >= 0; x--)
#define fore(x, a, b, c) for (int x = a; x <= b; x += c)
#define forre(x, a, b, c) for (int x = a; x >= b; x -= c)
#define clr cin.ignore(numeric_limits<streamsize>::max(), '\n')
#define all(container... | [["-", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 64, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["-", 8, 9, 0, 1, 0, 16, 12, 5, 0, 6], ["+", 8, 9, 0, 1, 0, 16, 12, 5, 0, 6]] | 1 | 275 |
#include <bits/stdc++.h>
using namespace std;
const string YES = "Yes";
const string NO = "No";
void solve(std::string S) {
if (S.size() % 2) {
cout << YES << endl;
return;
}
for (int i = 0; i < S.size(); i += 2) {
if (S[i] == 'h' && S[i + 1] == 'i')
continue;
cout << NO << endl;
retur... | #include <bits/stdc++.h>
using namespace std;
const string YES = "Yes";
const string NO = "No";
void solve(std::string S) {
if (S.size() % 2) {
cout << NO << endl;
return;
}
for (int i = 0; i < S.size(); i += 2) {
if (S[i] == 'h' && S[i + 1] == 'i')
continue;
cout << NO << endl;
return... | [["-", 64, 9, 0, 1, 0, 16, 31, 16, 12, 22], ["+", 64, 9, 0, 1, 0, 16, 31, 16, 12, 22]] | 1 | 136 |
s = input()
s.replace('hi', '')
if s:
print('No')
else:
print('Yes') | s = input()
s = s.replace('hi', '')
if s:
print('No')
else:
print('Yes')
| [["+", 36, 36, 0, 656, 0, 1, 0, 662, 0, 32], ["+", 0, 1, 0, 662, 12, 652, 63, 319, 500, 22]] | 5 | 33 |
S = input()
S_size = len(S)
S_hi = S.count('hi')
if S_size == S_hi:
print('Yes')
else:
print('No')
| S = input()
S_size = len(S)
S_hi = S.count('hi')
if S_size == S_hi*2:
print('Yes')
else:
print('No') | [["+", 0, 656, 0, 57, 15, 666, 0, 657, 17, 48], ["+", 0, 656, 0, 57, 15, 666, 0, 657, 12, 612]] | 5 | 40 |
S=input()
if len(S)%2 != 0:
print("No")
exit()
for i in range(int(len(S)/2)):
if S[i*2]!="h":
print("No")
exit()
if S[i*2+1]!="i":
Print("No")
exit()
print("Yes") | S=str(input())
if len(S)%2 != 0:
print("No")
exit()
for i in range(int(len(S)/2)):
if S[i*2]!="h":
print("No")
exit()
if S[i*2+1]!="i":
print("No")
exit()
print("Yes") | [["+", 0, 656, 0, 1, 0, 662, 12, 652, 63, 22], ["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 24], ["+", 0, 1, 0, 662, 12, 652, 3, 4, 0, 25], ["-", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22], ["+", 0, 57, 64, 196, 0, 1, 0, 652, 63, 22]] | 5 | 90 |
S = input()
if len(S) % 2 != 0:
print("No")
exit()
for i in range(len(S)-1):
if i % 2 == 0:
if S[i] == "h":
pass
else:
print("No")
exit()
else:
if S[i] == "i":
pass
else:
print("No")
exit()
pri... | S = input()
if len(S) % 2 != 0:
print("No")
exit()
for i in range(len(S)):
if i % 2 == 0:
if S[i] == "h":
pass
else:
print("No")
exit()
else:
if S[i] == "i":
pass
else:
print("No")
exit()
print... | [["-", 0, 7, 12, 652, 3, 4, 0, 657, 17, 33], ["-", 0, 7, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 96 |
#include <algorithm>
#include <deque>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
#define rep1(i, n) for (long long i = 0; i < (long long)(n); i++)
#define rep2(i, n, m) \
for (long long i = (long long)(n); i <= (long long)(m)... | #include <algorithm>
#include <deque>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
#define rep1(i, n) for (long long i = 0; i < (long long)(n); i++)
#define rep2(i, n, m) \
for (long long i = (long long)(n); i <= (long long)(m)... | [["+", 0, 1, 0, 2, 3, 4, 0, 25, 0, 35], ["+", 0, 30, 0, 14, 8, 9, 0, 9, 0, 45], ["+", 0, 1, 0, 11, 12, 16, 12, 23, 0, 24], ["+", 0, 1, 0, 11, 12, 16, 12, 23, 0, 25], ["+", 0, 30, 0, 14, 8, 9, 0, 9, 0, 46]] | 1 | 209 |
s = input()
if s == 'hi' * int(len(s)//2):
print('Yes')
else:
'No' | s = input()
if s == 'hi' * int(len(s)//2):
print('Yes')
else:
print('No') | [["+", 75, 76, 8, 196, 0, 1, 0, 652, 63, 22], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 24], ["+", 8, 196, 0, 1, 0, 652, 3, 4, 0, 25]] | 5 | 33 |
hitachi = list(input())
if len(hitachi) % 2 == 1:
print("NO")
else:
H = True
for i in range(len(hitachi)):
if i % 2 == 0:
if hitachi[i] != "h":
H = False
else:
if hitachi[i] != "i":
H = False
if H == True:
print("YES")
... | hitachi = list(input())
if len(hitachi) % 2 == 1:
print("No")
else:
H = True
for i in range(len(hitachi)):
if i % 2 == 0:
if hitachi[i] != "h":
H = False
else:
if hitachi[i] != "i":
H = False
if H == True:
print("Yes")
... | [["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]] | 5 | 94 |
S = input()
length = len(S)
if length % 2 == 0:
if n.count('hi')==length/2:
print("Yes")
else:
print("No")
else:
print("No") | S = input()
length = len(S)
if length % 2 == 0:
if S.count('hi')==length/2:
print("Yes")
else:
print("No")
else:
print("No") | [["-", 0, 57, 15, 666, 0, 652, 63, 319, 500, 22], ["+", 0, 57, 15, 666, 0, 652, 63, 319, 500, 22]] | 5 | 54 |
S = input()
X = ["hi" * i for i in range(5)]
if S in X:
print("Yes")
else:
print("No")
| S = input()
X = ["hi" * i for i in range(1, 5+1)]
if S in X:
print("Yes")
else:
print("No")
| [["+", 12, 658, 0, 659, 12, 652, 3, 4, 0, 612], ["+", 12, 658, 0, 659, 12, 652, 3, 4, 0, 21], ["+", 0, 659, 12, 652, 3, 4, 0, 657, 17, 72], ["+", 0, 659, 12, 652, 3, 4, 0, 657, 12, 612]] | 5 | 40 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.