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> #include <random> using namespace std; typedef unsigned long long ull; typedef long long ll; typedef double ld; //#define ll __int128 //#define int ll //#define int ll //#define char ll #define double ld typedef vector<char> vc; typedef vector<vc> vvc; typedef vector<vvc> vvvc; typedef pair<i...
#include <bits/stdc++.h> #include <random> using namespace std; typedef unsigned long long ull; typedef long long ll; typedef double ld; //#define ll __int128 //#define int ll //#define int ll //#define char ll #define double ld typedef vector<char> vc; typedef vector<vc> vvc; typedef vector<vvc> vvvc; typedef pair<i...
[["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 72], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["-", 0, 1, 0, 2, 3, 4, 0, 16, 17, 47], ["+", 0, 1, 0, 2, 3, 4, 0, 16, 17, 18]]
1
1,220
#include <algorithm> #include <deque> #include <stdio.h> #include <vector> using namespace std; int m[555][555]; int d[555][555]; int dx[4] = {1, 0, -1, 0}, dy[4] = {0, 1, 0, -1}; typedef pair<int, int> pii; int main() { int num; scanf("%d", &num); for (int i = 0; i < num; i++) { for (int j = 0; j < num; j++)...
#include <algorithm> #include <deque> #include <stdio.h> #include <vector> using namespace std; int m[555][555]; int d[555][555]; int dx[4] = {1, 0, -1, 0}, dy[4] = {0, 1, 0, -1}; typedef pair<int, int> pii; int main() { int num; scanf("%d", &num); for (int i = 0; i < num; i++) { for (int j = 0; j < num; j++)...
[["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 72], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13]]
1
500
#include <bits/stdc++.h> #define debug(...) fprintf(stderr, __VA_ARGS__) #ifndef AT_HOME #define getchar() IO::myGetchar() #define putchar(x) IO::myPutchar(x) #endif namespace IO { static const int IN_BUF = 1 << 23, OUT_BUF = 1 << 23; inline char myGetchar() { static char buf[IN_BUF], *ps = buf, *pt = buf; if (...
#include <bits/stdc++.h> #define debug(...) fprintf(stderr, __VA_ARGS__) #ifndef AT_HOME #define getchar() IO::myGetchar() #define putchar(x) IO::myPutchar(x) #endif namespace IO { static const int IN_BUF = 1 << 23, OUT_BUF = 1 << 23; inline char myGetchar() { static char buf[IN_BUF], *ps = buf, *pt = buf; if (...
[["+", 0, 14, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 8, 123, 0, 14, 8, 9, 0, 1, 0, 35]]
1
1,189
#include <algorithm> #include <bitset> #include <cassert> #include <chrono> #include <climits> #include <cmath> #include <complex> #include <cstdint> #include <cstring> #include <deque> #include <functional> #include <iomanip> #include <iostream> #include <list> #include <map> #include <numeric> #include <queue> #inclu...
#include <algorithm> #include <bitset> #include <cassert> #include <chrono> #include <climits> #include <cmath> #include <complex> #include <cstdint> #include <cstring> #include <deque> #include <functional> #include <iomanip> #include <iostream> #include <list> #include <map> #include <numeric> #include <queue> #inclu...
[["-", 0, 7, 8, 9, 0, 7, 15, 16, 12, 22], ["+", 0, 7, 15, 16, 12, 2, 63, 118, 28, 22], ["+", 0, 7, 15, 16, 12, 2, 63, 118, 17, 131], ["+", 0, 7, 15, 16, 12, 2, 63, 118, 119, 120], ["+", 0, 7, 15, 16, 12, 2, 3, 4, 0, 24], ["+", 0, 7, 15, 16, 12, 2, 3, 4, 0, 25]]
1
622
#pragma region Macros #pragma GCC optimize("O3") #include <bits/stdc++.h> #define ll long long #define ld long double #define rep2(i, a, b) for (ll i = a; i <= b; ++i) #define rep(i, n) for (ll i = 0; i < n; ++i) #define rep3(i, a, b) for (ll i = a; i >= b; --i) #define pii pair<int, int> #define pll pair<ll, ll> #def...
#pragma region Macros #pragma GCC optimize("O3") #include <bits/stdc++.h> #define ll long long #define ld long double #define rep2(i, a, b) for (ll i = a; i <= b; ++i) #define rep(i, n) for (ll i = 0; i < n; ++i) #define rep3(i, a, b) for (ll i = a; i >= b; --i) #define pii pair<int, int> #define pll pair<ll, ll> #def...
[["-", 0, 14, 8, 9, 0, 1, 0, 2, 63, 22], ["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22], ["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["-", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]]
1
2,486
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <vector> #define sqr(x) ((x) * (x)) #define fz1(i, n) for ((i) = 1; (i) <= (n);...
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <vector> #define sqr(x) ((x) * (x)) #define fz1(i, n) for ((i) = 1; (i) <= (n);...
[["+", 0, 14, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]]
1
809
#include <bits/stdc++.h> using namespace std; int n, m, rt, sz, val[888888], son[888888][3], tag[888888], ans[888888], all; char s[222222]; void build(int &nw, int c, int dep, int sum) { nw = ++sz; if (dep == n) { val[nw] = sum; return; } build(son[nw][0], c * 3, dep + 1, sum); build(son[nw][1], c * 3...
#include <bits/stdc++.h> using namespace std; int n, m, rt, sz, val[888888], son[888888][3], tag[888888], ans[888888], all; char s[222222]; void build(int &nw, int c, int dep, int sum) { nw = ++sz; if (dep == n) { val[nw] = sum; return; } build(son[nw][0], c * 3, dep + 1, sum); build(son[nw][1], c * 3...
[["+", 0, 14, 8, 9, 0, 1, 0, 2, 63, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 24], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 22], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 25], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]]
1
608
#include <bits/stdc++.h> typedef long long ll; using namespace std; int n, Q; string s; void update(int x, vector<int> &d, vector<int> &salsas) { if (salsas[x] != Q) { salsas[x] ^= 1; if (d[x] == 1) d[x] = 2; else if (d[x] == 2) d[x] = 1; } } pair<vector<int>, vector<int>> solve(vector<...
#include <bits/stdc++.h> typedef long long ll; using namespace std; int n, Q; string s; void update(int x, vector<int> &d, vector<int> &salsas) { if (salsas[x] != Q) { salsas[x] ^= 1; if (d[x] == 1) d[x] = 2; else if (d[x] == 2) d[x] = 1; } } pair<vector<int>, vector<int>> solve(vector<...
[["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]]
1
835
#include <bits/stdc++.h> using namespace std; using int64 = long long; constexpr int DEBUG = 0; int Power3(int p) { int r = 1; for (int i = 0; i < p; i++) { r *= 3; } return r; } int main() { ios::sync_with_stdio(false); cin.tie(0); int n; cin >> n; string original_command; cin >> original_...
#include <bits/stdc++.h> using namespace std; using int64 = long long; constexpr int DEBUG = 0; int Power3(int p) { int r = 1; for (int i = 0; i < p; i++) { r *= 3; } return r; } int main() { ios::sync_with_stdio(false); cin.tie(0); int n; cin >> n; string original_command; cin >> original_...
[["-", 8, 9, 0, 1, 0, 2, 63, 118, 119, 120], ["+", 8, 9, 0, 1, 0, 2, 63, 118, 119, 120]]
1
491
#include <bits/stdc++.h> //#include <boost/multiprecision/cpp_int.hpp> //#include <ext/pb_ds/assoc_container.hpp> //#include <ext/pb_ds/tree_policy.hpp> #pragma GCC optimize("O3") #define REP(i, n) for (int i = 0; i < n; i++) #define REPP(i, n) for (int i = 1; i <= n; i++) #define ALL(obj) (obj).begin(), (obj).end() #d...
#include <bits/stdc++.h> //#include <boost/multiprecision/cpp_int.hpp> //#include <ext/pb_ds/assoc_container.hpp> //#include <ext/pb_ds/tree_policy.hpp> #pragma GCC optimize("O3") #define REP(i, n) for (int i = 0; i < n; i++) #define REPP(i, n) for (int i = 1; i <= n; i++) #define ALL(obj) (obj).begin(), (obj).end() #d...
[["+", 0, 43, 49, 50, 51, 16, 31, 69, 28, 22], ["+", 49, 50, 51, 16, 31, 69, 341, 342, 0, 70], ["+", 49, 50, 51, 16, 31, 69, 341, 342, 0, 73]]
1
820
#include <bits/stdc++.h> #define mp make_pair #define pb push_back #define all(x) x.begin(), x.end() #define cmin(a, b) (a > b ? a = b : a) #define cmax(a, b) (a < b ? a = b : a) #define mem(a, k) memset(a, k, sizeof(a)) #define lop(i, s, t) for (int i = s; i < (t); ++i) #define rep(i, s, t) for (int i = s; i <= (t); +...
#include <bits/stdc++.h> #define mp make_pair #define pb push_back #define all(x) x.begin(), x.end() #define cmin(a, b) (a > b ? a = b : a) #define cmax(a, b) (a < b ? a = b : a) #define mem(a, k) memset(a, k, sizeof(a)) #define lop(i, s, t) for (int i = s; i < (t); ++i) #define rep(i, s, t) for (int i = s; i <= (t); +...
[["-", 0, 91, 28, 69, 28, 69, 341, 342, 0, 22], ["+", 0, 91, 28, 69, 28, 69, 341, 342, 0, 22], ["-", 12, 23, 0, 91, 28, 69, 341, 342, 0, 22], ["+", 12, 23, 0, 91, 28, 69, 341, 342, 0, 22]]
1
668
#include <algorithm> #include <functional> #include <iomanip> #include <iostream> #include <queue> #include <vector> using namespace std; using LL = long long; const int N = 505; int p[N * N]; int vis[N][N]; int dis[N][N]; bool mk[N][N]; int n, ans; int dx[]{1, -1, 0, 0}; int dy[]{0, 0, 1, -1}; void dij(int x, int ...
#include <algorithm> #include <functional> #include <iomanip> #include <iostream> #include <queue> #include <vector> using namespace std; using LL = long long; const int N = 505; int p[N * N]; int vis[N][N]; int dis[N][N]; bool mk[N][N]; int n, ans; int dx[]{1, -1, 0, 0}; int dy[]{0, 0, 1, -1}; void dij(int x, int ...
[["-", 12, 16, 31, 69, 28, 69, 341, 342, 0, 22], ["+", 12, 16, 31, 69, 28, 69, 341, 342, 0, 22], ["-", 51, 16, 12, 16, 31, 69, 341, 342, 0, 22], ["+", 51, 16, 12, 16, 31, 69, 341, 342, 0, 22]]
1
549
#include <algorithm> #include <array> #include <bitset> #include <cassert> #include <climits> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <functional> #include <iomanip> #include <iostream> #include <list> #include <map> #include <queue> #include <random> #include ...
#include <algorithm> #include <array> #include <bitset> #include <cassert> #include <climits> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <functional> #include <iomanip> #include <iostream> #include <list> #include <map> #include <queue> #include <random> #include ...
[["+", 8, 9, 0, 14, 8, 9, 0, 163, 0, 164], ["+", 8, 9, 0, 14, 8, 9, 0, 163, 15, 13], ["+", 8, 9, 0, 14, 8, 9, 0, 163, 0, 165], ["-", 8, 9, 0, 14, 8, 9, 0, 163, 0, 164], ["-", 8, 9, 0, 14, 8, 9, 0, 163, 15, 13], ["-", 8, 9, 0, 14, 8, 9, 0, 163, 0, 165]]
1
741
import sys input = sys.stdin.readline from collections import deque n = int(input()) a = list(map(int,input().split())) n += 2 ls = [0 for i in range(n*n)] for i in range(n): for j in range(n): ls[i*n+j] = min(i,j,n-1-i,n-1-j)-1 ans = 0 st = [0]*(n*n) for i in a: x,y = divmod(i-1,n-2) i = (x+1)*n+(y+1) ans ...
import sys input = sys.stdin.readline from collections import deque n = int(input()) a = list(map(int,input().split())) n += 2 ls = [0 for i in range(n*n)] for i in range(n): for j in range(n): ls[i*n+j] = min(i,j,n-1-i,n-1-j)-1 ans = 0 st = [0]*(n*n) for i in a: x,y = divmod(i-1,n-2) i = (x+1)*n+(y+1) ans ...
[["-", 64, 196, 0, 57, 15, 666, 0, 206, 51, 22], ["+", 64, 196, 0, 57, 15, 666, 0, 206, 51, 22]]
5
265
N, *P = map(int, open(0).read().split()) dp = [0] + [min(i, j, N + 1 - i, N + 1 - j) for i in range(N) for j in range(N)] memo = [1] * (N * N + 1) def move(fr, to): if dp[to] > dp[fr] + memo[fr]: dp[to] = dp[fr] + memo[fr] S.append(to) ans = 0 for p in P: ans += dp[p] memo[p] = 0 S =...
N, *P = map(int, open(0).read().split()) dp = [0] + [min(i, j, N - 1 - i, N - 1 - j) for i in range(N) for j in range(N)] memo = [1] * (N * N + 1) def move(fr, to): if dp[to] > dp[fr] + memo[fr]: dp[to] = dp[fr] + memo[fr] S.append(to) ans = 0 for p in P: ans += dp[p] memo[p] = 0 S =...
[["-", 8, 652, 3, 4, 0, 657, 31, 657, 17, 72], ["+", 8, 652, 3, 4, 0, 657, 31, 657, 17, 33]]
5
226
#include "bits/stdc++.h" using namespace std; using lint = long long int; using pint = pair<int, int>; using plint = pair<lint, lint>; #define ALL(x) (x).begin(), (x).end() #define SZ(x) ((lint)(x).size()) #define POW2(n) (1LL << (n)) #define FOR(i, begin, end) \ fo...
#include "bits/stdc++.h" using namespace std; using lint = long long int; using pint = pair<int, int>; using plint = pair<lint, lint>; #define ALL(x) (x).begin(), (x).end() #define SZ(x) ((lint)(x).size()) #define POW2(n) (1LL << (n)) #define FOR(i, begin, end) \ fo...
[["-", 0, 16, 31, 23, 0, 16, 12, 16, 17, 20], ["+", 0, 16, 31, 23, 0, 16, 12, 16, 17, 47], ["+", 75, 76, 0, 1, 0, 11, 12, 16, 17, 72], ["+", 75, 76, 0, 1, 0, 11, 12, 16, 12, 13]]
1
730
///****In the name of ALLAH, most Gracious, most Compassionate****// #pragma GCC target("avx2") #pragma GCC optimization("O3") #pragma GCC optimization("unroll-loops") #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> pii; #define ALL(a) a.begin(), a.end() #define FastIO ...
///****In the name of ALLAH, most Gracious, most Compassionate****// #pragma GCC target("avx2") #pragma GCC optimization("O3") #pragma GCC optimization("unroll-loops") #include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> pii; #define ALL(a) a.begin(), a.end() #define FastIO ...
[["-", 0, 43, 49, 50, 51, 16, 12, 69, 28, 22], ["+", 0, 43, 49, 50, 51, 16, 12, 69, 28, 22]]
1
865
#include <bits/stdc++.h> #define sz(x) ((ll)(x).size()) #define pb push_back #define all(x) (x).begin(), (x).end() #define prt(x) cout << (x) #define prtl(x) cout << (x) << endl #define rep(i, a, b) for (ll i = a; i < b; i++) #define mp(a, b) make_pair(a, b) #pragma GCC optimize("O3") using namespace std; using vi = ve...
#include <bits/stdc++.h> #define sz(x) ((ll)(x).size()) #define pb push_back #define all(x) (x).begin(), (x).end() #define prt(x) cout << (x) #define prtl(x) cout << (x) << endl #define rep(i, a, b) for (ll i = a; i < b; i++) #define mp(a, b) make_pair(a, b) #pragma GCC optimize("O3") using namespace std; using vi = ve...
[["-", 64, 9, 0, 1, 0, 11, 12, 16, 17, 72], ["-", 64, 9, 0, 1, 0, 11, 12, 16, 12, 13]]
1
1,110
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < n; i++) #define repn(i, n) for (int i = 1; i <= n; i++) #define LL long long #define pii pair<int, int> #define fi first #define se second #define pb push_back #define mpr make_pair using namespace std; const LL MOD = 1e9 + 7; int n, a[250010], dist[510...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < n; i++) #define repn(i, n) for (int i = 1; i <= n; i++) #define LL long long #define pii pair<int, int> #define fi first #define se second #define pb push_back #define mpr make_pair using namespace std; const LL MOD = 1e9 + 7; int n, a[250010], dist[510...
[["+", 49, 50, 51, 16, 31, 16, 31, 23, 0, 24], ["+", 51, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["+", 51, 16, 31, 16, 31, 23, 0, 16, 12, 13], ["+", 49, 50, 51, 16, 31, 16, 31, 23, 0, 25], ["+", 8, 9, 0, 43, 49, 50, 51, 16, 17, 72], ["+", 8, 9, 0, 43, 49, 50, 51, 16, 12, 13]]
1
464
from collections import defaultdict, deque, Counter from heapq import heappush, heappop, heapify import math import bisect import random from itertools import permutations, accumulate, combinations, product import sys import string from bisect import bisect_left, bisect_right from math import factorial, ceil, floor, co...
from collections import defaultdict, deque, Counter from heapq import heappush, heappop, heapify import math import bisect import random from itertools import permutations, accumulate, combinations, product import sys import string from bisect import bisect_left, bisect_right from math import factorial, ceil, floor, co...
[["-", 0, 677, 12, 634, 0, 206, 51, 319, 319, 22], ["-", 0, 1, 0, 677, 12, 634, 0, 206, 0, 70], ["+", 0, 677, 12, 634, 0, 652, 63, 319, 319, 22], ["+", 0, 677, 12, 634, 0, 652, 3, 4, 0, 24], ["-", 0, 1, 0, 677, 12, 634, 0, 206, 0, 73], ["+", 0, 677, 12, 634, 0, 652, 3, 4, 0, 25]]
5
1,017
#include <bits/stdc++.h> typedef long long int ll; typedef long double ld; #define pb push_back #define pii pair<ll, ll> #define F first #define S second #define endl '\n' #define int long long #define sync \ ios_base::sync_with_stdio(false); ...
#include <bits/stdc++.h> typedef long long int ll; typedef long double ld; #define pb push_back #define pii pair<ll, ll> #define F first #define S second #define endl '\n' #define int long long #define sync \ ios_base::sync_with_stdio(false); ...
[["-", 36, 36, 36, 36, 0, 30, 0, 14, 39, 78], ["+", 36, 36, 36, 36, 0, 30, 0, 14, 39, 40]]
1
669
#include <iostream> #include <set> #include <string> #include <vector> using namespace std; int mod = 1000000007; int inv = (mod + 1) / 2; int add(int x, int y) { int c = x + y; if (c >= mod) c -= mod; return c; } int sub(int x, int y) { int c = x - y; if (c < 0) c += mod; return c; } int mlt(int x,...
#include <iostream> #include <set> #include <string> #include <vector> using namespace std; int mod = 1000000007; int inv = (mod + 1) / 2; int add(int x, int y) { int c = x + y; if (c >= mod) c -= mod; return c; } int sub(int x, int y) { int c = x - y; if (c < 0) c += mod; return c; } int mlt(in...
[["-", 8, 9, 0, 57, 64, 9, 0, 9, 0, 45], ["-", 0, 14, 8, 9, 0, 7, 8, 9, 0, 46], ["-", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 12, 13], ["+", 0, 57, 64, 9, 0, 57, 64, 9, 0, 45], ["+", 0, 57, 64, 9, 0, 57, 64, 9, 0, 46]]
1
762
#include <bits/stdc++.h> using namespace std; typedef long long int ll; typedef long double ld; typedef pair<ll, ll> p2; ll p[5005], tr[5005], fac[5005], par[5005], dp[5005][5005], hell = pow(10, 9) + 7; ll find(ll i) { if (par[i] == i) return i; return par[i] = find(par[i]); } void merge(ll a, ll b) { a ...
#include <bits/stdc++.h> using namespace std; typedef long long int ll; typedef long double ld; typedef pair<ll, ll> p2; ll p[5005], tr[5005], fac[5005], par[5005], dp[5005][5005], hell = pow(10, 9) + 7; ll find(ll i) { if (par[i] == i) return i; return par[i] = find(par[i]); } void merge(ll a, ll b) { a ...
[["-", 0, 1, 0, 34, 31, 11, 12, 69, 28, 22], ["-", 0, 34, 31, 11, 12, 69, 341, 342, 0, 70], ["+", 0, 1, 0, 34, 31, 11, 12, 2, 63, 22], ["+", 0, 34, 31, 11, 12, 2, 3, 4, 0, 24], ["-", 0, 34, 31, 11, 12, 69, 341, 342, 0, 73], ["+", 0, 34, 31, 11, 12, 2, 3, 4, 0, 25], ["-", 0, 1, 0, 34, 12, 11, 12, 69, 28, 22], ["-", 0, 3...
1
753
#include <bits/stdc++.h> using namespace std; typedef long long ll; template <class T> bool chmax(T &a, const T &b) { if (a < b) { a = b; return true; } return false; } template <class T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return true; } return false; } #define all(x) (x).beg...
#include <bits/stdc++.h> using namespace std; typedef long long ll; template <class T> bool chmax(T &a, const T &b) { if (a < b) { a = b; return true; } return false; } template <class T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return true; } return false; } #define all(x) (x).beg...
[["-", 12, 16, 31, 23, 0, 16, 31, 16, 31, 22], ["+", 12, 16, 31, 23, 0, 16, 31, 16, 31, 22]]
1
916
#include <bits/stdc++.h> #include <stdlib.h> #include <sys/time.h> #include <unistd.h> using namespace std; typedef long long ll; typedef pair<ll, ll> P; typedef pair<P, ll> T; typedef pair<long double, ll> Ps; const ll INF = 2e18; const ll fact_table = 3200008; long double Pi = 3.1415926535897932384626; priority_q...
#include <bits/stdc++.h> #include <stdlib.h> #include <sys/time.h> #include <unistd.h> using namespace std; typedef long long ll; typedef pair<ll, ll> P; typedef pair<P, ll> T; typedef pair<long double, ll> Ps; const ll INF = 2e18; const ll fact_table = 3200008; long double Pi = 3.1415926535897932384626; priority_q...
[["-", 0, 7, 8, 9, 0, 1, 0, 11, 12, 22], ["+", 0, 7, 8, 9, 0, 1, 0, 11, 12, 22], ["+", 0, 1, 0, 11, 12, 16, 12, 23, 0, 24], ["+", 0, 1, 0, 11, 12, 16, 12, 23, 0, 25]]
1
1,523
#include <algorithm> #include <array> #include <bitset> #include <cassert> #include <complex> #include <cstdio> #include <cstring> #include <functional> #include <iomanip> #include <iostream> #include <iterator> #include <limits.h> #include <map> #include <math.h> #include <numeric> #include <queue> #include <random> #...
#include <algorithm> #include <array> #include <bitset> #include <cassert> #include <complex> #include <cstdio> #include <cstring> #include <functional> #include <iomanip> #include <iostream> #include <iterator> #include <limits.h> #include <map> #include <math.h> #include <numeric> #include <queue> #include <random> #...
[["-", 8, 9, 0, 1, 0, 2, 3, 4, 0, 13], ["+", 8, 9, 0, 1, 0, 2, 3, 4, 0, 13]]
1
2,464
#include <algorithm> #include <cmath> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <string> #include <tuple> #include <vector> #define mkp make_pair #define mkt make_tuple #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; typedef long long ll; const l...
#include <algorithm> #include <cmath> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <string> #include <tuple> #include <vector> #define mkp make_pair #define mkt make_tuple #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; typedef long long ll; const l...
[["-", 3, 4, 0, 16, 31, 16, 31, 23, 0, 24], ["-", 0, 16, 31, 16, 31, 23, 0, 16, 31, 22], ["-", 0, 16, 31, 16, 31, 23, 0, 16, 17, 33], ["-", 0, 16, 31, 16, 31, 23, 0, 16, 12, 13], ["-", 3, 4, 0, 16, 31, 16, 31, 23, 0, 25], ["-", 0, 2, 3, 4, 0, 16, 31, 16, 17, 48]]
1
1,405
#include <bits/stdc++.h> using namespace std; using lint = long long int; #define FOR(i, begin, end) \ for (int i = (begin), i##_end_ = (end); i < i##_end_; i++) #define IFOR(i, begin, end) \ for (int i = (end)-1,...
#include <bits/stdc++.h> using namespace std; using lint = long long int; #define FOR(i, begin, end) \ for (int i = (begin), i##_end_ = (end); i < i##_end_; i++) #define IFOR(i, begin, end) \ for (int i = (end)-1,...
[["-", 0, 14, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 110]]
1
691
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #define sf scanf #define pf printf #define pb push_back #define mp make_pair #define PI (acos(-1.0)) #define IN freopen("C.in", "r", stdin) #define OUT freopen("output.txt", "w", stdout) #define FOR(i, a, b) for (i ...
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #define sf scanf #define pf printf #define pb push_back #define mp make_pair #define PI (acos(-1.0)) #define IN freopen("C.in", "r", stdin) #define OUT freopen("output.txt", "w", stdout) #define FOR(i, a, b) for (i ...
[["-", 36, 36, 36, 36, 0, 30, 0, 43, 0, 21], ["+", 36, 36, 36, 36, 0, 30, 0, 43, 0, 35], ["+", 36, 36, 36, 36, 0, 30, 0, 43, 39, 40], ["-", 0, 7, 8, 9, 0, 57, 64, 93, 0, 94], ["+", 0, 7, 8, 9, 0, 57, 64, 116, 0, 117], ["-", 0, 43, 39, 344, 3, 347, 0, 77, 39, 40], ["+", 0, 43, 39, 344, 3, 347, 0, 77, 39, 78]]
1
1,149
#ifdef DEBUG #define _GLIBCXX_DEBUG #endif //#pragma GCC optimize("O3") #include <bits/stdc++.h> using namespace std; typedef long double ld; typedef long long ll; const int mod = (int)1e9 + 7; int mult(int a, int b) { return (1LL * a * b) % mod; } int sum(int a, int b) { int s = a + b; if (s >= mod) s -= mod; ...
#ifdef DEBUG #define _GLIBCXX_DEBUG #endif //#pragma GCC optimize("O3") #include <bits/stdc++.h> using namespace std; typedef long double ld; typedef long long ll; const int mod = (int)1e9 + 7; int mult(int a, int b) { return (1LL * a * b) % mod; } int sum(int a, int b) { int s = a + b; if (s >= mod) s -= mod; ...
[["-", 0, 43, 49, 50, 51, 16, 31, 16, 31, 22], ["+", 8, 9, 0, 43, 49, 50, 51, 16, 31, 22], ["-", 8, 9, 0, 43, 49, 50, 51, 16, 17, 33], ["-", 8, 9, 0, 43, 49, 50, 51, 16, 12, 22]]
1
709
d = {n: 'hon' for n in "24579"} d.update({n: 'pon' for n in "0168"}) d.update({3: 'bon'}) print(d[input()[-1]])
d = {n: 'hon' for n in "24579"} d.update({n: 'pon' for n in "0168"}) d.update({"3": 'bon'}) print(d[input()[-1]])
[["+", 3, 4, 0, 680, 0, 569, 448, 557, 0, 654], ["+", 3, 4, 0, 680, 0, 569, 448, 557, 0, 655]]
5
58
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int t = n % 10; if (n == 3) cout << "bon"; else if (n == 1 || n == 0 || n == 6 || n == 8) cout << "pon"; else cout << "hon"; }
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int t = n % 10; if (t == 3) cout << "bon"; else if (t == 1 || t == 0 || t == 6 || t == 8) cout << "pon"; else cout << "hon"; }
[["-", 8, 9, 0, 57, 15, 339, 51, 16, 31, 22], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 31, 22], ["-", 51, 16, 31, 16, 31, 16, 31, 16, 31, 22], ["+", 51, 16, 31, 16, 31, 16, 31, 16, 31, 22], ["-", 51, 16, 31, 16, 31, 16, 12, 16, 31, 22], ["+", 51, 16, 31, 16, 31, 16, 12, 16, 31, 22], ["-", 15, 339, 51, 16, 31, 16, 12, 16, 31...
1
70
N = int(input()) if N == 2 or N == 4 or N == 5 or\ N == 7 or N == 9: print('hon') elif N == 0 or N == 1 or N == 6 or\ N == 8: print('pon') else: print('bon')
N = int(input()) N = N%10 if N == 2 or N == 4 or N == 5 or\ N == 7 or N == 9: print('hon') elif N == 0 or N == 1 or N == 6 or\ N == 8: print('pon') else: print('bon')
[["+", 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, 657, 31, 22], ["+", 0, 656, 0, 1, 0, 662, 12, 657, 17, 109], ["+", 0, 656, 0, 1, 0, 662, 12, 657, 12, 612]]
5
68
x = input() N = int(x) if N % 10 == 2 or N % 10 == 4 or N % 10 == 5 or N % 10 == 7 or N % 10 == 9: print('hon') if N % 10 == 3: print('bon') else: print('pon')
x = input() N = int(x) if N % 10 == 2 or N % 10 == 4 or N % 10 == 5 or N % 10 == 7 or N % 10 == 9: print('hon') elif N % 10 == 3: print('bon') else: print('pon')
[["-", 36, 36, 36, 36, 0, 656, 0, 57, 0, 121], ["+", 36, 36, 0, 656, 0, 57, 75, 665, 0, 683]]
5
69
N = input() N = list(N) if N[len(N)-1] == '3': print('bon') elif N[len(N)-1] == 0 or N[len(N)-1] == 1 or N[len(N)-1] == 6 or N[len(N)-1] == 8: print('pon') else: print('hon')
N = input() N = list(N) if N[len(N)-1] == '3': print('bon') elif N[len(N)-1] == '0' or N[len(N)-1] == '1' or N[len(N)-1] == '6' or N[len(N)-1] == '8': print('pon') else: print('hon')
[["+", 31, 679, 31, 679, 31, 666, 0, 557, 0, 654], ["+", 31, 679, 31, 679, 31, 666, 0, 557, 0, 655], ["+", 31, 679, 31, 679, 12, 666, 0, 557, 0, 654], ["+", 31, 679, 31, 679, 12, 666, 0, 557, 0, 655], ["+", 15, 679, 31, 679, 12, 666, 0, 557, 0, 654], ["+", 15, 679, 31, 679, 12, 666, 0, 557, 0, 655], ["+", 75, 665, 15, ...
5
95
<?php $N = trim(fgets(STDIN)); $array = str_split($N, 1); if (preg_match('/[24579]/', end($array))) { echo 'hon'; } else if(preg_match('/[0168]/', end($array))){ echo 'pon'; } else if(preg_match('/[3]/', end($array))) { echo 'bob'; }
<?php $N = trim(fgets(STDIN)); $array = str_split($N, 1); if (preg_match('/[24579]/', end($array))) { echo 'hon'; } else if(preg_match('/[0168]/', end($array))){ echo 'pon'; } else if(preg_match('/[3]/', end($array))) { echo 'bon'; }
[["-", 8, 57, 8, 9, 0, 608, 0, 557, 0, 610], ["+", 8, 57, 8, 9, 0, 608, 0, 557, 0, 610]]
6
91
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; using ll = long long; using P = pair<int, int>; int main() { int n; cin >> n; int ans = n % 10; if (ans = 3) { cout << "bon" << endl; } else if (ans == 0 || ans == 1 || ans == 6 || ans == 8) { cout << "pon" ...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; using ll = long long; using P = pair<int, int>; int main() { int n; cin >> n; int ans = n % 10; if (ans == 3) { cout << "bon" << endl; } else if (ans == 0 || ans == 1 || ans == 6 || ans == 8) { cout << "pon"...
[["-", 8, 9, 0, 57, 15, 339, 51, 11, 17, 32], ["+", 8, 9, 0, 57, 15, 339, 51, 16, 17, 60]]
1
106
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; vector<string> shit = {"pon", "pon", "hon", "bon", "hon", "hon", "pon", "hon", "pon", "hon"}; cout << shit[s[0] - '0'] << endl; }
#include <bits/stdc++.h> using namespace std; int main() { string s; cin >> s; vector<string> shit = {"pon", "pon", "hon", "bon", "hon", "hon", "pon", "hon", "pon", "hon"}; cout << shit[s.back() - '0'] << endl; }
[["-", 341, 342, 0, 16, 31, 69, 341, 342, 0, 70], ["-", 341, 342, 0, 16, 31, 69, 341, 342, 0, 13], ["-", 341, 342, 0, 16, 31, 69, 341, 342, 0, 73], ["+", 341, 342, 0, 16, 31, 2, 63, 118, 17, 131], ["+", 341, 342, 0, 16, 31, 2, 63, 118, 119, 120], ["+", 341, 342, 0, 16, 31, 2, 3, 4, 0, 24], ["+", 341, 342, 0, 16, 31, 2,...
1
83
n = input() word = n[-1] if word == "3": print(n + "bon") elif word == "0" or word == "1" or word == "6" or word == "8": print(n + "pon") else: print(n + "hon")
n = input() word = n[-1] if word == "3": print("bon") elif word == "0" or word == "1" or word == "6" or word == "8": print("pon") else: print("hon")
[["-", 0, 1, 0, 652, 3, 4, 0, 657, 31, 22], ["-", 0, 1, 0, 652, 3, 4, 0, 657, 17, 72]]
5
70
N=input() if N[-1]==3: print ("bon") elif N[-1]==0 or N[-1]==8 or N[-1]==6 or N[-1]==1: print("pon") else: print("hon")
N=input() if N[-1]=="3": print ("bon") elif N[-1]=="0" or N[-1]=="8" or N[-1]=="6" or N[-1]=="1": print("pon") else: print("hon")
[["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 654], ["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 655], ["+", 31, 679, 31, 679, 31, 666, 0, 557, 0, 654], ["+", 31, 679, 31, 679, 31, 666, 0, 557, 0, 655], ["+", 31, 679, 31, 679, 12, 666, 0, 557, 0, 654], ["+", 31, 679, 31, 679, 12, 666, 0, 557, 0, 655], ["+", 15, 679, 31, 679, 1...
5
67
#include <stdio.h> int main() { char nums[4]; scanf("%s", nums); char firstPlace; int i = 0; while (nums[i] != '\0') { firstPlace = nums[i]; i++; } switch (firstPlace) { case '0': case '1': case '6': case '8': puts("hon\n"); break; case '2': case '4': case '5': case '7':...
#include <stdio.h> int main() { char nums[4]; scanf("%s", nums); char firstPlace; int i = 0; while (nums[i] != '\0') { firstPlace = nums[i]; i++; } switch (firstPlace) { case '0': case '1': case '6': case '8': puts("pon\n"); break; case '2': case '4': case '5': case '7':...
[["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]]
0
143
N=(input()) x = N[-1] A =[2,4,5,7,9] if x in A: print('hon') elif x == '3': print('bon') else: print('pon')
N=(input()) x = int(N[-1]) A =[2,4,5,7,9] if x in A: print('hon') elif x == 3: print('bon') else: print('pon')
[["+", 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, 75, 665, 15, 666, 0, 557, 0, 654], ["-", 0, 57, 75, 665, 15, 666, 0, 557, 0, 655]]
5
59
N = int(input()) if N == 3: print("bon") elif N == 0 or N == 1 or N == 6 or N == 8: print("pon") else: print("hon")
N = int(input()) N %= 10 if N == 3: print("bon") elif N == 0 or N == 1 or N == 6 or N == 8: print("pon") else: print("hon")
[["+", 36, 36, 0, 656, 0, 1, 0, 677, 31, 22], ["+", 36, 36, 0, 656, 0, 1, 0, 677, 17, 132], ["+", 36, 36, 0, 656, 0, 1, 0, 677, 12, 612]]
5
50
#include <bits/stdc++.h> #include <iostream> using namespace std; #define ll long long const ll mod = 1e9 + 7; const ll INF = 1e14; void solve() { int n; cin >> n; if (n % 10 == 3) cout << "bon"; else if (n % 10 == 0 || n % 10 == 1 || n % 10 == 6 || 8) cout << "pon"; else cout << "hon"; } i...
#include <bits/stdc++.h> #include <iostream> using namespace std; #define ll long long const ll mod = 1e9 + 7; const ll INF = 1e14; void solve() { int n; cin >> n; if (n % 10 == 3) cout << "bon"; else if (n % 10 == 0 || n % 10 == 1 || n % 10 == 6 || n % 10 == 8) cout << "pon"; else cout << "...
[["+", 15, 339, 51, 16, 12, 16, 31, 16, 31, 22], ["+", 15, 339, 51, 16, 12, 16, 31, 16, 17, 109], ["+", 15, 339, 51, 16, 12, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 17, 60]]
1
118
N = int(input()) N = N % 10 if N in (2, 4, 5, 7, 9): print ("hon") elif N in (0, 1, 6, 7): print ("pon") elif N == 3: print ("bon")
N = int(input()) N = N % 10 if N in (2, 4, 5, 7, 9): print ("hon") elif N in (0, 1, 6, 8): print ("pon") elif N == 3: print ("bon")
[["-", 0, 57, 75, 665, 15, 666, 0, 660, 0, 612], ["+", 0, 57, 75, 665, 15, 666, 0, 660, 0, 612]]
5
64
n = input() c = n[-1] if c in ["24579"]: print("hon") elif c in ["0168"]: print("pon") else: print("bon")
n = input() c = n[-1] if c in "24579": print("hon") elif c in "0168": print("pon") else: print("bon")
[["-", 0, 656, 0, 57, 15, 666, 0, 634, 0, 70], ["-", 0, 656, 0, 57, 15, 666, 0, 634, 0, 73], ["-", 0, 57, 75, 665, 15, 666, 0, 634, 0, 70], ["-", 0, 57, 75, 665, 15, 666, 0, 634, 0, 73]]
5
50
N = input () P = '1689' H = '2457' if N[-1] in P: print ('pon') elif N[-1] in H: print ('hon') else: print ('bon')
N = input () P = '0168' H = '24579' if N[-1] in P: print ('pon') elif N[-1] in H: print ('hon') else: print ('bon')
[["-", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6], ["+", 0, 656, 0, 1, 0, 662, 12, 557, 0, 6]]
5
53
#include <algorithm> #include <bitset> #include <cassert> #include <ciso646> #include <cmath> #include <complex> #include <cstdio> #include <functional> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <random> #include <set> #include <stack> #include <string> #include <tuple> #include <u...
#include <algorithm> #include <bitset> #include <cassert> #include <ciso646> #include <cmath> #include <complex> #include <cstdio> #include <functional> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <random> #include <set> #include <stack> #include <string> #include <tuple> #include <u...
[["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]]
1
316
n = int(input()) a = n % 10 if a == 3: print('bon') elif a == 0 | a == 1 | a == 6 | a == 8: print('pon') else: print('hon')
n = int(input()) a = n % 10 if a == 3: print('bon') elif a == 0 or a == 1 or a == 6 or a == 8: print('pon') else: print('hon')
[["-", 0, 57, 75, 665, 15, 666, 0, 657, 17, 139], ["+", 75, 665, 15, 679, 31, 679, 31, 679, 17, 354], ["+", 0, 57, 75, 665, 15, 679, 31, 679, 17, 354], ["+", 0, 656, 0, 57, 75, 665, 15, 679, 17, 354]]
5
55
#include <algorithm> #include <cmath> #include <functional> #include <iostream> #include <numeric> #include <set> #include <string> #include <vector> #define ll long long int #define rep(i, n) for (int i = 0; i < n; i++) using namespace std; int main() { ll N, nx, e, ecnt, a, con = 0; cin >> N; nx = N; if (N...
#include <algorithm> #include <cmath> #include <functional> #include <iostream> #include <numeric> #include <set> #include <string> #include <vector> #define ll long long int #define rep(i, n) for (int i = 0; i < n; i++) using namespace std; int main() { ll N, nx, e, ecnt, a, con = 0; cin >> N; nx = N; if (N...
[["-", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]]
1
140
mylist1 = [2,4,5,7,9] mylist2 = [0,1,6,8] N = int(input()) X = N % 10 if X in mylsit1: print('hon') elif X in mylist2: print('pon') else: print('bon')
mylist1 = [2,4,5,7,9] mylist2 = [0,1,6,8] N = int(input()) X = N % 10 if X in mylist1: print('hon') elif X in mylist2: print('pon') else: print('bon')
[["-", 36, 36, 0, 656, 0, 57, 15, 666, 0, 22], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 0, 22]]
5
67
#include <iostream> using namespace std; int main() { int n; cin >> n; if (n % 10 == '0' || n % 10 == '1' || n % 10 == '6' || n % 10 == '8') cout << "pon"; else if (n % 10 == '3') cout << "bon"; else cout << "hon"; }
#include <iostream> using namespace std; int main() { int n; cin >> n; if (n % 10 == 0 || n % 10 == 1 || n % 10 == 6 || n % 10 == 8) cout << "pon"; else if (n % 10 == 3) cout << "bon"; else cout << "hon"; }
[["-", 31, 16, 31, 16, 31, 16, 12, 103, 0, 104], ["-", 31, 16, 31, 16, 12, 16, 12, 103, 0, 104], ["-", 51, 16, 31, 16, 12, 16, 12, 103, 0, 104], ["-", 15, 339, 51, 16, 12, 16, 12, 103, 0, 104], ["-", 0, 57, 15, 339, 51, 16, 12, 103, 0, 104]]
1
83
N = int(input()) if (N % 10 == 0) or (N % 10 == 1) or (N % 10 == 6) or (N % 10 == 8): print("pon") elif (N % 10 == 3): print("bon") else: print("bon")
N = int(input()) if (N % 10 == 0) or (N % 10 == 1) or (N % 10 == 6) or (N % 10 == 8): print("pon") elif N % 10 == 3: print("bon") else: print("hon")
[["-", 0, 656, 0, 57, 75, 665, 15, 23, 0, 24], ["-", 0, 656, 0, 57, 75, 665, 15, 23, 0, 25], ["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]]
5
70
#include <bits/stdc++.h> using namespace std; int main() { int a; if (a % 10 == 3) { cout << "bon"; } else if (a % 10 == 0 || a % 10 == 1 || a % 10 == 6 || a % 10 == 8) { cout << "pon"; } else { cout << "hon"; } }
#include <bits/stdc++.h> using namespace std; int main() { int a; cin >> a; if (a % 10 == 3) { cout << "bon"; } else if (a % 10 == 0 || a % 10 == 1 || a % 10 == 6 || a % 10 == 8) { cout << "pon"; } else { cout << "hon"; } }
[["+", 0, 14, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 16, 17, 152], ["+", 0, 14, 8, 9, 0, 1, 0, 16, 12, 22], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]]
1
75
n = int(input()) n = n[-1] if n in [2, 4, 5, 7, 9]: ans = 'hon' elif n in [0, 1, 6, 8]: ans = 'pon' else: ans = 'bon' print(ans)
n = input() n = int(n[-1]) if n in [2, 4, 5, 7, 9]: ans = 'hon' elif n in [0, 1, 6, 8]: ans = 'pon' else: ans = 'bon' print(ans)
[["-", 0, 656, 0, 1, 0, 662, 12, 652, 63, 22], ["-", 0, 1, 0, 662, 12, 652, 3, 4, 0, 24], ["-", 12, 652, 3, 4, 0, 652, 3, 4, 0, 25], ["+", 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]]
5
64
N = int(input()) e = int(N[-1]) if e in (2,4,5,7,9): print('hon') elif e in (0,1,6,8): print('pon') else: print('bon')
N = input() e = int(N[-1]) if e in (2,4,5,7,9): print('hon') elif e in (0,1,6,8): print('pon') else: print('bon')
[["-", 0, 656, 0, 1, 0, 662, 12, 652, 63, 22], ["-", 0, 1, 0, 662, 12, 652, 3, 4, 0, 24], ["-", 12, 652, 3, 4, 0, 652, 3, 4, 0, 25]]
5
66
N = int(input()) r = N % 10 char = ["pon", "pon", "hon", "bon", "hon", "hon", "pon", "hon", "Pon", "hon"] print(char[r])
N = int(input()) r = N % 10 char = ["pon", "pon", "hon", "bon", "hon", "hon", "pon", "hon", "pon", "hon"] print(char[r])
[["-", 0, 1, 0, 662, 12, 634, 0, 557, 0, 6], ["+", 0, 1, 0, 662, 12, 634, 0, 557, 0, 6]]
5
63
#include <bits/stdc++.h> #define IOS \ ios::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0); ...
#include <bits/stdc++.h> #define IOS \ ios::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0); ...
[["-", 0, 57, 15, 339, 51, 16, 12, 103, 0, 104], ["-", 31, 16, 31, 16, 31, 16, 12, 103, 0, 104], ["-", 31, 16, 31, 16, 12, 16, 12, 103, 0, 104], ["-", 51, 16, 31, 16, 12, 16, 12, 103, 0, 104], ["-", 15, 339, 51, 16, 12, 16, 12, 103, 0, 104]]
1
92
#include <iostream> using namespace std; int main() { int a; int b; cin >> a; b = a % 10; if (b == 3) cout << "bon"; else if (b == 0 && b == 1 && b == 6 && b == 8) cout << "pon"; else cout << "hon"; return 0; }
#include <iostream> using namespace std; int main() { int a; int b; cin >> a; b = a % 10; if (b == 3) cout << "bon"; else if (b == 0 || b == 1 || b == 6 || b == 8) cout << "pon"; else cout << "hon"; return 0; }
[["-", 15, 339, 51, 16, 31, 16, 31, 16, 17, 98], ["+", 15, 339, 51, 16, 31, 16, 31, 16, 17, 106], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 106], ["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 98], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 106]]
1
75
s=input() if s[-1]==3: print('bon') elif s[-1] in [0,1,6,8]: print('pon') else: print('hon')
s=input() if s[-1]=='3': print('bon') elif s[-1] in ['0','1','6','8']: print('pon') else: print('hon')
[["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 654], ["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 655], ["+", 75, 665, 15, 666, 0, 634, 0, 557, 0, 654], ["+", 75, 665, 15, 666, 0, 634, 0, 557, 0, 655]]
5
51
/* author : nishi5451 created: 11.08.2020 23:17:00 */ #include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < n; i++) typedef long long ll; int main() { int n; cin >> n; n /= 10; switch (n) { case 3: cout << "bon" << endl; break; case 0: case 1: case 6: ...
/* author : nishi5451 created: 11.08.2020 23:17:00 */ #include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < n; i++) typedef long long ll; int main() { int n; cin >> n; n %= 10; switch (n) { case 3: cout << "bon" << endl; break; case 0: case 1: case 6: ...
[["-", 0, 14, 8, 9, 0, 1, 0, 11, 17, 90], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 132]]
1
93
print(('pphbhhphph'[int(input())])+'on')
print(('pphbhhphph'[int(input()[-1])])+'on')
[["+", 0, 206, 206, 652, 3, 4, 0, 206, 0, 70], ["+", 206, 652, 3, 4, 0, 206, 206, 664, 17, 33], ["+", 206, 652, 3, 4, 0, 206, 206, 664, 28, 612], ["+", 0, 206, 206, 652, 3, 4, 0, 206, 0, 73]]
5
20
"use strict"; const main = (input) => { const spi = input.split('\n'); const n = parseInt(spi[0]); n = (n % 100) % 10; if (n === 3) console.log("bon"); else if (n === 0 || n === 1 || n === 6 || n === 8) console.log("pon"); else console.log("hon"); }; main(require("fs").readFileSync("/dev/stdi...
"use strict"; const main = (input) => { const spi = input.split('\n'); let n = parseInt(spi[0]); n = (n % 100) % 10; if (n === 3) console.log("bon"); else if (n === 0 || n === 1 || n === 6 || n === 8) console.log("pon"); else console.log("hon"); }; main(require("fs").readFileSync("/dev/stdin"...
[["-", 0, 200, 51, 568, 8, 556, 0, 570, 571, 154], ["+", 0, 200, 51, 568, 8, 556, 0, 570, 571, 243]]
2
121
N = int(input()) A = [2, 4 , 5, 7, 9] B = [0, 1, 6, 8] C = [3] if N%10 in A: print("hon") if N%10 in B: print("pon") if N%10 in A: print("bon")
N = int(input()) A = [2, 4 , 5, 7, 9] B = [0, 1, 6, 8] C = [3] if N%10 in A: print("hon") if N%10 in B: print("pon") if N%10 in C: print("bon")
[["-", 36, 36, 0, 656, 0, 57, 15, 666, 0, 22], ["+", 36, 36, 0, 656, 0, 57, 15, 666, 0, 22]]
5
76
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int a = n % 10; if (a == 3) cout << "bon"; if (a == 0 or a == 1 or a == 6 or a == 8) cout << "pon"; else cout << "hon"; }
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int a = n % 10; if (a == 3) cout << "bon"; else if (a == 0 or a == 1 or a == 6 or a == 8) cout << "pon"; else cout << "hon"; }
[["+", 0, 14, 8, 9, 0, 57, 75, 76, 0, 95]]
1
69
#include <bits/stdc++.h> #define _GLIBCXX_DEBUG #define rep(i, n) for (int i = 0; i < (n); ++i) #define repi(i, a, b) for (int i = int(a); i < int(b); ++i) #define all(x) (x).begin(), (x).end() #define PI 3.14159265358979323846264338327950L using namespace std; typedef long long ll; typedef long double ld; int main() {...
#include <bits/stdc++.h> #define _GLIBCXX_DEBUG #define rep(i, n) for (int i = 0; i < (n); ++i) #define repi(i, a, b) for (int i = int(a); i < int(b); ++i) #define all(x) (x).begin(), (x).end() #define PI 3.14159265358979323846264338327950L using namespace std; typedef long long ll; typedef long double ld; int main() {...
[["-", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 12, 13], ["-", 31, 16, 31, 16, 31, 16, 31, 16, 12, 13], ["+", 31, 16, 31, 16, 31, 16, 31, 16, 12, 13], ["-", 31, 16, 31, 16, 12, 16, 31, 16, 12, 13], ["+", 31, 16, 31, 16, 12, 16, 31, 16, 12, 13], ["-", 51, 16, 31, 16, 12, 16, 31, 16,...
1
112
#include <iostream> using namespace std; int main() { int n; string ans; switch (n % 10) { case 3: cout << "bon\n"; break; case 0: case 1: case 6: case 8: cout << "pon\n"; break; default: cout << "hon\n"; break; } }
#include <iostream> using namespace std; int main() { int n; cin >> n; switch (n % 10) { case 3: cout << "bon\n"; break; case 0: case 1: case 6: case 8: cout << "pon\n"; break; default: cout << "hon\n"; break; } }
[["-", 0, 30, 0, 14, 8, 9, 0, 43, 39, 78], ["-", 0, 30, 0, 14, 8, 9, 0, 43, 49, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 16, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 16, 17, 152], ["+", 0, 14, 8, 9, 0, 1, 0, 16, 12, 22]]
1
70
#include <stdio.h> int main() { int n; scanf("%d", &n); if (n == 3) printf("bon"); else if (n == 0 || n == 1 || n == 6 || n == 8) printf("pon"); else { printf("hon"); } return 0; }
#include <stdio.h> int main() { int n; scanf("%d", &n); n = n % 10; if (n == 3) printf("bon"); else if (n == 0 || n == 1 || n == 6 || n == 8) printf("pon"); else { printf("hon"); } return 0; }
[["+", 0, 14, 8, 9, 0, 1, 0, 11, 31, 22], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 17, 32], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 31, 22], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 17, 109], ["+", 8, 9, 0, 1, 0, 11, 12, 16, 12, 13], ["+", 0, 30, 0, 14, 8, 9, 0, 1, 0, 35]]
0
73
#include <bits/stdc++.h> using namespace std; int main() { int N; cin >> N; N %= 100; if (N == 3) { cout << "bon" << endl; } else if (N == 0 || N == 1 || N == 6 || N == 8) { cout << "pon" << endl; } else { cout << "hon" << endl; } }
#include <bits/stdc++.h> using namespace std; int main() { int N; cin >> N; N %= 10; if (N == 3) { cout << "bon" << endl; } else if (N == 0 || N == 1 || N == 6 || N == 8) { cout << "pon" << endl; } else { cout << "hon" << endl; } }
[["-", 0, 14, 8, 9, 0, 1, 0, 11, 12, 13], ["+", 0, 14, 8, 9, 0, 1, 0, 11, 12, 13]]
1
79
#include <bits/stdc++.h> #include <string> using namespace std; int main() { string str, ans = "Hon"; cin >> str; int s = str.size() - 1; if (str.at(s) == '3') ans = "Bon"; if (str.at(s) == '0' || str.at(s) == '1' || str.at(s) == '6' || str.at(s) == '8') ans = "Pon"; cout << ans << endl; }
#include <bits/stdc++.h> #include <string> using namespace std; int main() { string str, ans = "hon"; cin >> str; int s = str.size() - 1; if (str.at(s) == '3') ans = "bon"; if (str.at(s) == '0' || str.at(s) == '1' || str.at(s) == '6' || str.at(s) == '8') ans = "pon"; cout << ans << endl; }
[["-", 8, 9, 0, 43, 49, 50, 51, 5, 0, 6], ["+", 8, 9, 0, 43, 49, 50, 51, 5, 0, 6], ["-", 0, 57, 64, 1, 0, 11, 12, 5, 0, 6], ["+", 0, 57, 64, 1, 0, 11, 12, 5, 0, 6]]
1
115
x = gets.to_i x %= 10 if x > 10 x %= 10 end case x when 0,2,4,5,7,9 puts "hon" when 1,6,8 puts "pon" when 3 puts "bon" end
x = gets.to_i x %= 10 if x > 10 x %= 10 end case x when 2,4,5,7,9 puts "hon" when 0,1,6,8 puts "pon" when 3 puts "bon" end
[["-", 0, 493, 0, 173, 0, 763, 374, 374, 0, 612], ["-", 36, 36, 0, 493, 0, 173, 0, 763, 0, 21], ["+", 0, 493, 0, 173, 0, 763, 374, 374, 0, 612], ["+", 36, 36, 0, 493, 0, 173, 0, 763, 0, 21]]
4
51
#include <fstream> #include <iostream> #include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; typedef long long ll; typedef pair<int, int> P; class ATherefore { public: void solve(std::istream &cin, std::ostream &cout) { int n; cin >> n; if (n % 10 == 3) { c...
/** * code generated by JHelper * More info: https://github.com/AlexeyDmitriev/JHelper * @author */ #include <fstream> #include <iostream> #include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; typedef long long ll; typedef pair<int, int> P; class ATherefore { public: voi...
[["-", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13], ["+", 0, 57, 15, 339, 51, 16, 12, 16, 12, 13]]
1
172
n = int(input()) a = n-(n//100)*100 b = a-(a//10)*10 print(b) if b == 2 or b == 4 or b == 5 or b == 7 or b == 9: print("hon") if b == 0 or b == 1 or b == 6 or b == 8: print("pon") if b == 3: print("bon")
n = int(input()) a = n-(n//100)*100 b = a-(a//10)*10 if b == 2 or b == 4 or b == 5 or b == 7 or b == 9: print("hon") if b == 0 or b == 1 or b == 6 or b == 8: print("pon") if b == 3: print("bon")
[["-", 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
95
number = input() if number[0] == '3': print('bon') elif number[0] in ['0', '6', '1', '8']: print('pon') else: print('hon')
number = input() if number[-1] == '3': print('bon') elif number[-1] in ['0', '6', '1', '8']: print('pon') else: print('hon')
[["-", 0, 656, 0, 57, 15, 666, 0, 206, 206, 612], ["+", 0, 57, 15, 666, 0, 206, 206, 664, 17, 33], ["+", 0, 57, 15, 666, 0, 206, 206, 664, 28, 612], ["-", 0, 57, 75, 665, 15, 666, 0, 206, 206, 612], ["+", 75, 665, 15, 666, 0, 206, 206, 664, 17, 33], ["+", 75, 665, 15, 666, 0, 206, 206, 664, 28, 612]]
5
59
"""AtCoder.""" n = int(input()) s = None if n in (2, 4, 5, 7, 9): s = 'hon' elif n in (0, 1, 6, 8): s = 'pon' elif n in (3,): s = 'bon' print(s)
"""AtCoder.""" n = int(input()[-1]) s = None if n in (2, 4, 5, 7, 9): s = 'hon' elif n in (0, 1, 6, 8): s = 'pon' elif n in (3,): s = 'bon' print(s)
[["+", 0, 662, 12, 652, 3, 4, 0, 206, 0, 70], ["+", 12, 652, 3, 4, 0, 206, 206, 664, 17, 33], ["+", 12, 652, 3, 4, 0, 206, 206, 664, 28, 612], ["+", 0, 662, 12, 652, 3, 4, 0, 206, 0, 73]]
5
69
# 1 # 2 # 3 n=input() a=n[0] if a in list('24579'): ans='hon' elif a in list('0168'): ans='pon' else: ans='bon' print(ans)
# 1 # 2 # 3 n=input() a=n[-1] if a in list('24579'): ans='hon' elif a in list('0168'): ans='pon' else: ans='bon' print(ans)
[["-", 0, 656, 0, 1, 0, 662, 12, 206, 206, 612], ["+", 0, 1, 0, 662, 12, 206, 206, 664, 17, 33], ["+", 0, 1, 0, 662, 12, 206, 206, 664, 28, 612]]
5
55
N=input() if N[-1]=="3": print("bon") elif N[-1] in ["1","6","8"]: print("pon") else: print("hon")
N=input() if N[-1]=="3": print("bon") elif N[-1] in ["0","1","6","8"]: print("pon") else: print("hon")
[["+", 75, 665, 15, 666, 0, 634, 0, 557, 0, 6], ["+", 75, 665, 15, 666, 0, 634, 0, 557, 0, 655], ["+", 0, 57, 75, 665, 15, 666, 0, 634, 0, 21], ["+", 75, 665, 15, 666, 0, 634, 0, 557, 0, 654]]
5
57
#include <bits/stdc++.h> using namespace std; int main() { string N; cin >> N; if (N[N.size() - 1] == '2' && N[N.size() - 1] == '4' && N[N.size() - 1] == '5' && N[N.size() - 1] == '7' && N[N.size() - 1] == '9') { cout << "hon" << endl; } else if (N[N.size() - 1] == '3') { cout << "bon" << e...
#include <bits/stdc++.h> using namespace std; int main() { string N; cin >> N; if (N[N.size() - 1] == '2' || N[N.size() - 1] == '4' || N[N.size() - 1] == '5' || N[N.size() - 1] == '7' || N[N.size() - 1] == '9') { cout << "hon" << endl; } else if (N[N.size() - 1] == '3') { cout << "bon" << e...
[["-", 51, 16, 31, 16, 31, 16, 31, 16, 17, 98], ["+", 51, 16, 31, 16, 31, 16, 31, 16, 17, 106], ["-", 15, 339, 51, 16, 31, 16, 31, 16, 17, 98], ["+", 15, 339, 51, 16, 31, 16, 31, 16, 17, 106], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 106], ["-", 8, 9, 0, 57, 15, 339, 51, ...
1
145
n=str(input()) if n[len(n)-1]==3: print("bon") elif n[len(n)-1]==2 or n[len(n)-1]==4 or n[len(n)-1]==5 or n[len(n)-1]==7 or n[len(n)-1]==9: print("hon") else: print("pon")
n=str(input()) if n[len(n)-1]=="3": print("bon") elif n[len(n)-1]=="2" or n[len(n)-1]=="4" or n[len(n)-1]=="5" or n[len(n)-1]=="7" or n[len(n)-1]=="9": print("hon") else: print("pon")
[["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 654], ["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 655], ["+", 31, 679, 31, 679, 31, 666, 0, 557, 0, 654], ["+", 31, 679, 31, 679, 31, 666, 0, 557, 0, 655], ["+", 31, 679, 31, 679, 12, 666, 0, 557, 0, 654], ["+", 31, 679, 31, 679, 12, 666, 0, 557, 0, 655], ["+", 15, 679, 31, 679, 1...
5
102
#include <bits/stdc++.h> using namespace std; #define ll long long int #define mp make_pair #define pb push_back #define F first #define S second #define mod 1000000007 #define dbg(n) cout << #n << ' ' << n << endl; #define dbg_v(v) \ cout << #v << ":"; ...
#include <bits/stdc++.h> using namespace std; #define ll long long int #define mp make_pair #define pb push_back #define F first #define S second #define mod 1000000007 #define dbg(n) cout << #n << ' ' << n << endl; #define dbg_v(v) \ cout << #v << ":"; ...
[["-", 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
178
#include <algorithm> #include <cctype> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <random> #include <stack> #include <string> #include <unordered_map> using namespace std; typedef long long ll; const ll INF = 1000000007; const ll mod = 1000000007...
#include <algorithm> #include <cctype> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <random> #include <stack> #include <string> #include <unordered_map> using namespace std; typedef long long ll; const ll INF = 1000000007; const ll mod = 1000000007...
[["-", 0, 1, 0, 16, 31, 16, 12, 103, 0, 104], ["-", 0, 1, 0, 16, 31, 16, 12, 103, 0, 125], ["-", 0, 16, 31, 16, 12, 103, 0, 42, 0, 22], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 62], ["+", 0, 1, 0, 16, 31, 16, 12, 5, 0, 6]]
1
176
#include <bits/stdc++.h> #define ll long long #define mp make_pair #define F first #define S second #define db double #define pb push_back #define rep(i, a, b) for (ll i = a; i <= b; i++) #define all(a) a.begin(), a.end() using namespace std; ll mod = 1e9 + 7; ll expo(ll base, ll exponent, ll mod) { ll ans = 1; w...
#include <bits/stdc++.h> #define ll long long #define mp make_pair #define F first #define S second #define db double #define pb push_back #define rep(i, a, b) for (ll i = a; i <= b; i++) #define all(a) a.begin(), a.end() using namespace std; ll mod = 1e9 + 7; ll expo(ll base, ll exponent, ll mod) { ll ans = 1; w...
[["-", 0, 52, 8, 9, 0, 1, 0, 11, 12, 22], ["+", 0, 52, 8, 9, 0, 1, 0, 11, 12, 13]]
1
448
n = input() if n[-1] == 3: print('bon') elif n[-1] in ['0', '1', '6', '8']: print('pon') else: print('hon')
n = input() if n[-1] == '3': print('bon') elif n[-1] in ['0', '1', '6', '8']: print('pon') else: print('hon')
[["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 654], ["+", 0, 656, 0, 57, 15, 666, 0, 557, 0, 655]]
5
59
// Problem : A - ∴ (Therefore) // Contest : AtCoder - AtCoder Beginner Contest 168 // URL : https://atcoder.jp/contests/abc168/tasks/abc168_a // Memory Limit : 1024 MB // Time Limit : 2000 ms // Powered by CP Editor (https://github.com/cpeditor/cpeditor) #include <bits/stdc++.h> using namespace std; int main() { i...
// Problem : A - ∴ (Therefore) // Contest : AtCoder - AtCoder Beginner Contest 168 // URL : https://atcoder.jp/contests/abc168/tasks/abc168_a // Memory Limit : 1024 MB // Time Limit : 2000 ms // Powered by CP Editor (https://github.com/cpeditor/cpeditor) #include <bits/stdc++.h> using namespace std; int main() { i...
[["-", 51, 16, 31, 16, 31, 16, 12, 16, 12, 13], ["+", 51, 16, 31, 16, 31, 16, 12, 16, 12, 13]]
1
99
// 12/07/2020 @ 19:54:17 // ***************************************************************** // ***************************************************************** #include <bits/stdc++.h> // ***************************************************************** // ***********************************************************...
// 12/07/2020 @ 19:54:17 // ***************************************************************** // ***************************************************************** #include <bits/stdc++.h> // ***************************************************************** // ***********************************************************...
[["-", 0, 43, 49, 50, 51, 16, 31, 23, 0, 24], ["-", 49, 50, 51, 16, 31, 23, 0, 16, 17, 85], ["-", 49, 50, 51, 16, 31, 23, 0, 16, 12, 13], ["-", 0, 43, 49, 50, 51, 16, 31, 23, 0, 25]]
1
260
#include <bits/stdc++.h> using namespace std; int main() { int n; scanf("%d", &n); if (n % 10 == 3) { printf("bon\n"); } else if (n % 10 == 0 && n % 10 == 1 && n % 10 == 6 && n % 10 == 8) { printf("pon\n"); } else { printf("hon\n"); } return 0; }
#include <bits/stdc++.h> using namespace std; int main() { int n; scanf("%d", &n); if (n % 10 == 3) { printf("bon\n"); } else if (n % 10 == 0 || n % 10 == 1 || n % 10 == 6 || n % 10 == 8) { printf("pon\n"); } else { printf("hon\n"); } return 0; }
[["-", 15, 339, 51, 16, 31, 16, 31, 16, 17, 98], ["+", 15, 339, 51, 16, 31, 16, 31, 16, 17, 106], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 106], ["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 98], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 106]]
1
94
#include <stdio.h> int main(void) { int n; scanf("%d", &n); switch (n % 10) { case 0: case 1: case 6: case 8: printf("hon"); break; case 3: printf("bon"); break; default: printf("hon"); break; } return 0; }
#include <stdio.h> int main(void) { int n; scanf("%d", &n); switch (n % 10) { case 0: case 1: case 6: case 8: printf("pon"); break; case 3: printf("bon"); break; default: printf("hon"); break; } return 0; }
[["-", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6], ["+", 0, 1, 0, 2, 3, 4, 0, 5, 0, 6]]
0
77
#include <stdio.h> using namespace std; typedef long long llong; #define MAX const llong mod = 1000000000 + 7; int main() { int n, i; char units[3][4] = {"bon", "pon", "hon"}; scanf("%d", &n); switch (n % 10) { case 3: i = 0; break; case 0: case 1: case 6: case 8: i = 1; default: ...
#include <stdio.h> using namespace std; typedef long long llong; #define MAX const llong mod = 1000000000 + 7; int main() { int n, i; char units[3][4] = {"bon", "pon", "hon"}; scanf("%d", &n); switch (n % 10) { case 3: i = 0; break; case 0: case 1: case 6: case 8: i = 1; break; d...
[["+", 0, 99, 8, 9, 0, 100, 0, 93, 0, 94], ["+", 0, 99, 8, 9, 0, 100, 0, 93, 0, 35]]
1
122
def main(): n = int(input()) if n % 10 == 3: print('bon') elif n % 10 == 0 or n % 1 == 1 or n % 10 == 6 or n % 10 == 8: print('pon') else: print('hon') main()
def main(): n = int(input()) if n % 10 == 3: print('bon') elif n % 10 == 0 or n % 10 == 1 or n % 10 == 6 or n % 10 == 8: print('pon') else: print('hon') main()
[["-", 31, 679, 31, 679, 12, 666, 0, 657, 12, 612], ["+", 31, 679, 31, 679, 12, 666, 0, 657, 12, 612]]
5
68
# A Therefore n = input() if n[2] in ["2", "4", "5", "7", "9"]: print("hon") elif n[2] in ["0", "1", "6", "8"]: print("pon") else: print("bon")
# A Therefore n = input() if n[-1] in ["2", "4", "5", "7", "9"]: print("hon") elif n[-1] in ["0", "1", "6", "8"]: print("pon") else: print("bon")
[["-", 0, 656, 0, 57, 15, 666, 0, 206, 206, 612], ["+", 0, 57, 15, 666, 0, 206, 206, 664, 17, 33], ["+", 0, 57, 15, 666, 0, 206, 206, 664, 28, 612], ["-", 0, 57, 75, 665, 15, 666, 0, 206, 206, 612], ["+", 75, 665, 15, 666, 0, 206, 206, 664, 17, 33], ["+", 75, 665, 15, 666, 0, 206, 206, 664, 28, 612]]
5
78
#include <bits/stdc++.h> using namespace std; typedef long long ll; #define all(v) v.begin(), v.end() int main() { int n, n1; cin >> n; n1 = n % 10; if (n1 == 3) { cout << "bon" << endl; } else if (n1 == 10 || n1 == 1 || n1 == 6 || n1 == 8) { cout << "pon" << endl; } else { cout << "hon" << end...
#include <bits/stdc++.h> using namespace std; typedef long long ll; #define all(v) v.begin(), v.end() int main() { int n, n1; cin >> n; n1 = n % 10; if (n1 == 3) { cout << "bon" << endl; } else if (n1 == 0 || n1 == 1 || n1 == 6 || n1 == 8) { cout << "pon" << endl; } else { cout << "hon" << endl...
[["-", 51, 16, 31, 16, 31, 16, 31, 16, 12, 13], ["+", 51, 16, 31, 16, 31, 16, 31, 16, 12, 13]]
1
94
#include <bits/stdc++.h> using namespace std; int main(void) { int N; cin >> N; string ans; if (N % 10 == 3) ans = "bon"; else if (N % 10 == 0 && N % 10 == 1 && N % 10 == 6 && N % 10 == 8) ans = "pon"; else ans = "hon"; cout << ans << endl; }
#include <bits/stdc++.h> using namespace std; int main(void) { int N; cin >> N; string ans; if (N % 10 == 3) ans = "bon"; else if (N % 10 == 0 || N % 10 == 1 || N % 10 == 6 || N % 10 == 8) ans = "pon"; else ans = "hon"; cout << ans << endl; }
[["-", 15, 339, 51, 16, 31, 16, 31, 16, 17, 98], ["+", 15, 339, 51, 16, 31, 16, 31, 16, 17, 106], ["-", 0, 57, 15, 339, 51, 16, 31, 16, 17, 98], ["+", 0, 57, 15, 339, 51, 16, 31, 16, 17, 106], ["-", 75, 76, 0, 57, 15, 339, 51, 16, 17, 98], ["+", 75, 76, 0, 57, 15, 339, 51, 16, 17, 106]]
1
83
l = ["p","p","h","b","h","h","p","h","p","h"] n = input() print(l[int(n[2])] + "on")
l = ["p","p","h","b","h","h","p","h","p","h"] n = input() print(l[int(n[-1])] + "on")
[["-", 31, 206, 206, 652, 3, 4, 0, 206, 206, 612], ["+", 206, 652, 3, 4, 0, 206, 206, 664, 17, 33], ["+", 206, 652, 3, 4, 0, 206, 206, 664, 28, 612]]
5
65
#include <cmath> #include <cstdio> #include <iostream> using namespace std; int main(void) { int N; scanf("%d", &N); string ans; switch (N % 10) { case 3: ans = "bon"; break; case 0: case 1: case 6: case 8: ans = "pon"; break; defalut: ans = "hon"; break; } cout << ans <...
#include <cmath> #include <cstdio> #include <iostream> using namespace std; int main(void) { int N; scanf("%d", &N); string ans = "hon"; switch (N % 10) { case 3: ans = "bon"; break; case 0: case 1: case 6: case 8: ans = "pon"; break; defalut: ans = "hon"; break; } cout ...
[["+", 0, 14, 8, 9, 0, 43, 49, 50, 0, 32], ["+", 8, 9, 0, 43, 49, 50, 51, 5, 0, 62], ["+", 8, 9, 0, 43, 49, 50, 51, 5, 0, 6]]
1
93
l =list(input()) print(l) if l[-1] == '3': print('bon') elif l[-1] in ['2','4','5','7','9']: print('hon') else: print('pon')
l =list(input()) #print(l) if l[-1] == '3': print('bon') elif l[-1] in ['2','4','5','7','9']: print('hon') else: print('pon')
[["-", 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
72
N = int(input()) a = N[-1] if a == 3: print('bon') elif a == 0 or a == 1 or a == 6 or a == 8: print('pon') else: print('hon')
N = int(input()) a = N%10 if a == 3: print('bon') elif a == 0 or a == 1 or a == 6 or a == 8: print('pon') else: print('hon')
[["-", 0, 656, 0, 1, 0, 662, 12, 206, 0, 70], ["-", 0, 1, 0, 662, 12, 206, 206, 664, 17, 33], ["-", 0, 1, 0, 662, 12, 206, 206, 664, 28, 612], ["-", 0, 656, 0, 1, 0, 662, 12, 206, 0, 73], ["+", 0, 656, 0, 1, 0, 662, 12, 657, 17, 109], ["+", 0, 656, 0, 1, 0, 662, 12, 657, 12, 612]]
5
57
N = input() hon = [2,4,5,7,9] pon = [0,1,6,8] if int(N[-1]) in hon: print('hon') elif int(N[-1]) in pon: print(pon) else: print('bon')
N = input() hon = [2,4,5,7,9] pon = [0,1,6,8] if int(N[-1]) in hon: print('hon') elif int(N[-1]) in pon: print('pon') else: print('bon')
[["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 654], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 655]]
5
71
def main(): n = int(input()) one = n%10 if one in [2, 4, 5, 7, 9]: print("hon") elif one == 2: print("bon") else: print("pon") if __name__ == "__main__": main()
def main(): n = int(input()) one = n%10 if one in [2, 4, 5, 7, 9]: print("hon") elif one == 3: print("bon") else: print("pon") if __name__ == "__main__": main()
[["-", 8, 196, 0, 57, 75, 665, 15, 666, 0, 612], ["+", 8, 196, 0, 57, 75, 665, 15, 666, 0, 612]]
5
68
n = input() a = int(n[-1]) if a==2 or a==2 or a==5 or a==7 or a==9: print('hon') elif a==0 or a==1 or a==6 or a==8: print('pon') else: print('bon')
n = input() a = int(n[-1]) if a==2 or a==4 or a==5 or a==7 or a==9: print('hon') elif a==0 or a==1 or a==6 or a==8: print('pon') else: print('bon')
[["-", 31, 679, 31, 679, 31, 679, 12, 666, 0, 612], ["+", 31, 679, 31, 679, 31, 679, 12, 666, 0, 612]]
5
73
N = int(input()) if N%10==2: print('hon') if N%10==4: print('hon') if N%10==5: print('hon') if N%10==6: print('pon') if N%10==7: print('hon') if N%10==8: print('hon') if N%10==9: print('hon') if N%10==0: print('pon') if N%10==1: print('pon') if N%10==3: print('bon')
N = int(input()) if N%10==2: print('hon') if N%10==4: print('hon') if N%10==5: print('hon') if N%10==6: print('pon') if N%10==7: print('hon') if N%10==8: print('pon') if N%10==9: print('hon') if N%10==0: print('pon') if N%10==1: print('pon') if N%10==3: print('bon')
[["-", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6], ["+", 0, 1, 0, 652, 3, 4, 0, 557, 0, 6]]
5
138