Datasets:

problem_id
stringlengths
6
6
buggy_code
stringlengths
8
526k
fixed_code
stringlengths
12
526k
labels
listlengths
0
15
⌀
buggy_submission_id
int64
1
1.54M
fixed_submission_id
int64
2
1.54M
user_id
stringlengths
10
10
language
stringclasses
8 values
p02255
#include <algorithm> #include <iostream> using namespace std; int main(void) { // Your code here! int N; cin >> N; int A[1001]; int i, j, v, k; for (i = 0; i < N; i++) { cin >> A[i]; } for (i = 0; i < N - 1; i++) { cout << A[i] << " "; } cout << A[i] << endl; for (i = 1; i < N; i++) { ...
#include <algorithm> #include <iostream> using namespace std; int main(void) { // Your code here! int N; cin >> N; int A[1001]; int i, j, v, k; for (i = 0; i < N; i++) { cin >> A[i]; } for (i = 0; i < N - 1; i++) { cout << A[i] << " "; } cout << A[i] << endl; for (i = 1; i < N; i++) { ...
[ "identifier.change", "variable_access.subscript.index.change", "io.output.change" ]
97,372
97,373
u121616304
cpp
p02255
#include <iostream> int N; //整数の長さN int A[100]; // N個の数列A int v; int i, j, k; int main() { std::cin >> N; for (i = 0; i < N; i++) { std::cin >> A[i]; } for (i = 0; i < N; i++) { if (i == N - 1) { std::cout << A[i]; } else std::cout << A[i] << ' '; } std::cout << std::endl; f...
#include <iostream> int N; //整数の長さN int A[100]; // N個の数列A int v; int i, j, k; int main() { std::cin >> N; for (i = 0; i < N; i++) { std::cin >> A[i]; } for (i = 0; i < N; i++) { if (i == N - 1) { std::cout << A[i]; } else std::cout << A[i] << ' '; } std::cout << std::endl; f...
[ "identifier.replace.remove", "literal.replace.add", "control_flow.branch.if.condition.change" ]
97,381
97,382
u451768946
cpp
p02255
#include <cstdio> using namespace std; int main() { int n; int a[100]; int v; scanf("%d", &n); for (int i = 0; i < n; i++) scanf("%d", &a[i]); for (int i = 1; i < n; i++) { v = a[i]; for (int j = i - 1; j >= 0; j--) { if (a[j] > v) { a[j + 1] = a[j]; a[j] = v; } el...
#include <cstdio> using namespace std; int main() { int n; int a[1000]; int v; scanf("%d", &n); for (int i = 0; i < n; i++) scanf("%d", &a[i]); for (int i = 0; i < n; i++) { v = a[i]; for (int j = i - 1; j >= 0; j--) { if (a[j] > v) { a[j + 1] = a[j]; a[j] = v; } e...
[ "literal.number.change", "variable_declaration.array_dimensions.change", "variable_declaration.value.change", "control_flow.loop.for.initializer.change", "expression.off_by_one" ]
97,384
97,385
u719381486
cpp
p02255
#include <algorithm> #include <iostream> #include <map> #include <queue> #include <stack> #include <string> #include <vector> using namespace std; typedef long long i64; #define put(n) cout << (n) << "\n" #define FOR(i, num, N) for (int(i) = (num); (i) < (N); (i)++) #define RFOR(i, num, N) for (int(i) = (num); (i) > (...
#include <algorithm> #include <iostream> #include <map> #include <queue> #include <stack> #include <string> #include <vector> using namespace std; typedef long long i64; #define put(n) cout << (n) << "\n" #define FOR(i, num, N) for (int(i) = (num); (i) < (N); (i)++) #define RFOR(i, num, N) for (int(i) = (num); (i) > (...
[ "literal.number.change", "call.arguments.change" ]
97,388
97,389
u334931708
cpp
p02255
#include <iostream> #include <string> #include <vector> using namespace std; void InputSet(std::vector<int> &a) { int n; cin >> n; a.resize(n, 0); for (int i = 0; i < n; ++i) { cin >> a.at(i); } } void Print(std::vector<int> &a) { for (int j = 0; j < (int)a.size(); ++j) { if (j == 0) { cout <...
#include <iostream> #include <string> #include <vector> using namespace std; void InputSet(std::vector<int> &a) { int n; cin >> n; a.resize(n, 0); for (int i = 0; i < n; ++i) { cin >> a.at(i); } } void Print(std::vector<int> &a) { for (int j = 0; j < (int)a.size(); ++j) { if (j == 0) { cout <...
[ "call.add" ]
97,393
97,394
u084809388
cpp
p02255
#include <iostream> using namespace std; int input[100]; int output[100]; int number = 0; void insertion_sort(int a[]); void print(int a[]); int main() { cin >> number; for (int i = 0; i < number; i++) { cin >> input[i]; } insertion_sort(input); } void insertion_sort(int a[]) { for (int j = 1; j < nu...
#include <iostream> using namespace std; int input[100]; int output[100]; int number = 0; void insertion_sort(int a[]); void print(int a[]); int main() { cin >> number; for (int i = 0; i < number; i++) { cin >> input[i]; } insertion_sort(input); } void insertion_sort(int a[]) { print(a); for (int j...
[ "call.add" ]
97,395
97,396
u918188633
cpp
p02255
#include <cstdio> #include <iostream> using namespace std; int main() { int n; int a[100]; cin >> n; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = 1; i < n; i++) { int j; int tmp = a[i]; for (j = 0; j < i; j++) { if (a[i] < a[j]) { break; } } for (int k = ...
#include <cstdio> #include <iostream> using namespace std; int main() { int n; int a[100]; cin >> n; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = 0; i < n; i++) { int j; int tmp = a[i]; for (j = 0; j < i; j++) { if (a[i] < a[j]) { break; } } for (int k = ...
[ "literal.number.change", "variable_declaration.value.change", "control_flow.loop.for.initializer.change", "expression.off_by_one" ]
97,402
97,403
u261898944
cpp
p02255
#include <iostream> #include <vector> using namespace std; int main(void) { int n; cin >> n; vector<int> a(n); for (int i = 0; i < n; ++i) cin >> a[i]; for (int j = 0; j < n; ++j) cout << a[j] << ((j == n - 1) ? "\n" : " "); for (int i = 1; i <= n; ++i) { int key = a[i], j = i - 1; for (; j...
#include <iostream> #include <vector> using namespace std; int main(void) { int n; cin >> n; vector<int> a(n); for (int i = 0; i < n; ++i) cin >> a[i]; for (int j = 0; j < n; ++j) cout << a[j] << ((j == n - 1) ? "\n" : " "); for (int i = 1; i < n; ++i) { int key = a[i], j = i - 1; for (; j ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
97,404
97,405
u256940798
cpp
p02255
#include <iostream> #include <vector> using namespace std; int main() { int n, a; vector<int> v(1, 0); cin >> n; while (n--) { cin >> a; v.push_back(a); } for (int j = 2; j < v.size(); j++) { int key = v[j], i = j - 1; while (i > 0 && v[i] > key) { v[i + 1] = v[i]; i--; } ...
#include <iostream> #include <vector> using namespace std; int main() { int n, a; vector<int> v(1, 0); cin >> n; while (n--) { cin >> a; v.push_back(a); } for (int j = 1; j < v.size(); j++) { int key = v[j], i = j - 1; while (i > 0 && v[i] > key) { v[i + 1] = v[i]; i--; } ...
[ "literal.number.change", "variable_declaration.value.change", "control_flow.loop.for.initializer.change", "expression.off_by_one" ]
97,406
97,407
u095377734
cpp
p02255
#include <iostream> using namespace std; void showArray(int *datas, int n) { int i; for (i = 0; i < n - 1; i++) { cout << datas[i] << " "; } cout << datas[n] << endl; } int main() { int n, i, j, k, key; cin >> n; int datas[1000]; for (i = 0; i < n; i++) { cin >> datas[i]; } for (j = 1; j ...
#include <iostream> using namespace std; void showArray(int *datas, int n) { int i; for (i = 0; i < n - 1; i++) { cout << datas[i] << " "; } cout << datas[n - 1] << endl; } int main() { int n, i, j, k, key; cin >> n; int datas[1000]; for (i = 0; i < n; i++) { cin >> datas[i]; } for (j = 1;...
[ "expression.operation.binary.add" ]
97,408
97,409
u111688608
cpp
p02255
#include <iostream> #define REP(i, a, b) for (i = a; i < b; i++) #define rep(i, n) REP(i, 0, n) #define N 1000 using namespace std; void trace(int A[], int n) { int i; rep(i, n) { if (i > 0) cout << " "; cout << A[i]; } cout << endl; } int main() { int n, A[N + 1]; int i, j, key; // inp...
#include <iostream> #define REP(i, a, b) for (i = a; i < b; i++) #define rep(i, n) REP(i, 0, n) #define N 1000 using namespace std; void trace(int A[], int n) { int i; rep(i, n) { if (i > 0) cout << " "; cout << A[i]; } cout << endl; } int main() { int n, A[N + 1]; int i, j, key; // inp...
[ "expression.operation.binary.remove" ]
97,410
97,411
u328607523
cpp
p02255
#include <iostream> #include <vector> int main() { int n; std::cin >> n; std::vector<int> A(n); for (int i = 0; i < 6; ++i) std::cin >> A[i]; for (int i = 1; i < n - 1; ++i) { for (int k = 0; k < n; ++k) { if (k != n - 1) std::cout << A[k] << ' '; else std::cout << A[k] <<...
#include <iostream> #include <vector> int main() { int n; std::cin >> n; std::vector<int> A(n); for (int i = 0; i < n; ++i) std::cin >> A[i]; for (int i = 1; i < n; ++i) { for (int k = 0; k < n; ++k) { if (k != n - 1) std::cout << A[k] << ' '; else std::cout << A[k] << std...
[ "identifier.replace.add", "literal.replace.remove", "control_flow.loop.for.condition.change", "expression.operation.binary.change", "expression.operation.binary.remove" ]
97,418
97,419
u376194616
cpp
p02255
#include <iostream> #include <vector> int main() { int n; std::cin >> n; std::vector<int> A(n); for (int i = 0; i < n; ++i) std::cin >> A[i]; for (int i = 1; i < n - 1; ++i) { for (int k = 0; k < n; ++k) { if (k != n - 1) std::cout << A[k] << ' '; else std::cout << A[k] <<...
#include <iostream> #include <vector> int main() { int n; std::cin >> n; std::vector<int> A(n); for (int i = 0; i < n; ++i) std::cin >> A[i]; for (int i = 1; i < n; ++i) { for (int k = 0; k < n; ++k) { if (k != n - 1) std::cout << A[k] << ' '; else std::cout << A[k] << std...
[ "control_flow.loop.for.condition.change", "expression.operation.binary.remove" ]
97,420
97,419
u376194616
cpp
p02255
#include <bits/stdc++.h> using namespace std; using LL = long long; using VI = vector<int>; using PI = pair<int, int>; int main() { int n; cin >> n; vector<int> a(n); for (int i = 0; i < n; i++) { cin >> a[i]; } for (int i = 0; i < n - 1; i++) { int v = a[i]; int j = i - 1; while (j >= 0 &...
#include <bits/stdc++.h> using namespace std; using LL = long long; using VI = vector<int>; using PI = pair<int, int>; int main() { int n; cin >> n; vector<int> a(n); for (int i = 0; i < n; i++) { cin >> a[i]; } for (int i = 0; i < n; i++) { int v = a[i]; int j = i - 1; while (j >= 0 && a[...
[ "control_flow.loop.for.condition.change", "expression.operation.binary.remove" ]
97,426
97,427
u146806866
cpp
p02255
#include <bits/stdc++.h> using namespace std; int main() { int N; cin >> N; int a[N]; for (int i = 0; i < N; i++) { cin >> a[i]; } for (int k = 0; k < N - 1; k++) { cout << a[k] << " "; } cout << a[N]; cout << endl; int j, v; for (int i = 1; i <= N - 1; i++) { v = a[i]; j = i - 1; ...
#include <bits/stdc++.h> using namespace std; int main() { int N; cin >> N; int a[N]; for (int i = 0; i < N; i++) { cin >> a[i]; } for (int k = 0; k < N - 1; k++) { cout << a[k] << " "; } cout << a[N - 1]; cout << endl; int j, v; for (int i = 1; i <= N - 1; i++) { v = a[i]; j = i -...
[ "expression.operation.binary.add" ]
97,428
97,429
u460296825
cpp
p02255
#include <iostream> #include <vector> using namespace std; void printVector(const vector<int> &A) { for (int i = 0; i < A.size(); i++) { cout << A[i]; if (i + 1 < A.size()) cout << ' '; } cout << endl; } int main() { int n; cin >> n; vector<int> A(n); for (int i = 0; i < n; i++) cin...
#include <iostream> #include <vector> using namespace std; void printVector(const vector<int> &A) { for (int i = 0; i < A.size(); i++) { cout << A[i]; if (i + 1 < A.size()) cout << ' '; } cout << endl; } int main() { int n; cin >> n; vector<int> A(n); for (int i = 0; i < n; i++) cin...
[ "literal.number.change", "variable_declaration.value.change", "control_flow.loop.for.initializer.change", "expression.off_by_one", "call.remove" ]
97,430
97,431
u842986906
cpp
p02255
#include <algorithm> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <math.h> #include <sstream> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <string> //#include <vector> using namespace std; int main(void) { int n, a[100]; cin >> n; for (int i = 0; i <...
#include <algorithm> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <math.h> #include <sstream> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <string> //#include <vector> using namespace std; int main(void) { int n, a[100]; cin >> n; for (int i = 0; i <...
[ "io.output.change" ]
97,438
97,439
u615852561
cpp
p02255
#include <iostream> using namespace std; int main() { int n; cin >> n; int a[n]; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = 1; i < n; i++) { for (int i = 0; i < n - 1; i++) cout << a[i] << " "; cout << a[n - 1] << endl; int v = a[i]; int j = i - 1; while ((j >= 0) ...
#include <iostream> using namespace std; int main() { int n; cin >> n; int a[n]; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = 1; i < n; i++) { for (int i = 0; i < n - 1; i++) cout << a[i] << " "; cout << a[n - 1] << endl; int v = a[i]; int j = i - 1; while ((j >= 0) ...
[ "literal.number.change", "variable_declaration.value.change", "control_flow.loop.for.initializer.change", "expression.off_by_one" ]
97,440
97,441
u833446151
cpp
p02255
#include <algorithm> #include <cmath> #include <cstdio> #include <cstdlib> #include <iostream> #include <list> #include <map> #include <vector> using namespace std; void trace(vector<int> v) { for (int i = 0; i < v.size(); i++) { if (i != 0) { cout << " "; } cout << v[i]; } cout << endl; } vo...
#include <algorithm> #include <cmath> #include <cstdio> #include <cstdlib> #include <iostream> #include <list> #include <map> #include <vector> using namespace std; void trace(vector<int> v) { for (int i = 0; i < v.size(); i++) { if (i != 0) { cout << " "; } cout << v[i]; } cout << endl; } vo...
[ "call.remove", "call.add" ]
97,443
97,444
u664925358
cpp
p02255
#include <algorithm> #include <cmath> #include <cstdio> #include <cstdlib> #include <iostream> #include <list> #include <map> #include <vector> using namespace std; void trace(vector<int> v) { for (int i = 0; i < v.size(); i++) { if (i != 0) { cout << " "; } cout << v[i]; } cout << endl; } vo...
#include <algorithm> #include <cmath> #include <cstdio> #include <cstdlib> #include <iostream> #include <list> #include <map> #include <vector> using namespace std; void trace(vector<int> v) { for (int i = 0; i < v.size(); i++) { if (i != 0) { cout << " "; } cout << v[i]; } cout << endl; } vo...
[ "call.add" ]
97,445
97,444
u664925358
cpp
p02255
#include <iostream> using namespace std; int main() { int n; cin >> n; int a[n]; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = 1; i < n; i++) { int v = a[i]; int j = i - 1; while (j >= 0 && v < a[j]) { a[j + 1] = a[j]; j--; } a[j + 1] = v; for (int k = 0; k < n ...
#include <iostream> using namespace std; int main() { int n; cin >> n; int a[n]; for (int i = 0; i < n; i++) cin >> a[i]; for (int i = 0; i < n; i++) { int v = a[i]; int j = i - 1; while (j >= 0 && v < a[j]) { a[j + 1] = a[j]; j--; } a[j + 1] = v; for (int k = 0; k < n ...
[ "literal.number.change", "variable_declaration.value.change", "control_flow.loop.for.initializer.change", "expression.off_by_one" ]
97,449
97,450
u840099192
cpp
p02248
#include <iostream> #include <string> #include <vector> #define CLEN 256 using namespace std; template <typename T> std::vector<std::vector<T>> makeMatrix(int row, int col) { std::vector<std::vector<T>> vv(row); for (auto it = vv.begin(); it != vv.end(); it++) { (*it).resize(col); } return vv; } vector<ve...
#include <iostream> #include <string> #include <vector> #define CLEN 256 using namespace std; template <typename T> std::vector<std::vector<T>> makeMatrix(int row, int col) { std::vector<std::vector<T>> vv(row); for (auto it = vv.begin(); it != vv.end(); it++) { (*it).resize(col); } return vv; } vector<ve...
[ "assignment.add" ]
97,765
97,766
u808404363
cpp
p02248
#include <iostream> #include <string> #include <vector> using namespace std; using int_vec = vector<int>; int_vec kmp_table(const string &p) { auto m = p.size(); int_vec A(m + 1); A[0] = -1; int j = -1; for (int i = 0; i < m; ++i) { while (j >= 0 && p[i] != p[j]) j = A[j]; j++; A[i + 1] =...
#include <iostream> #include <string> #include <vector> using namespace std; using int_vec = vector<int>; int_vec kmp_table(const string &p) { auto m = p.size(); int_vec A(m + 1); A[0] = -1; int j = -1; for (int i = 0; i < m; ++i) { while (j >= 0 && p[i] != p[j]) j = A[j]; j++; A[i + 1] =...
[ "expression.operation.binary.remove" ]
97,767
97,768
u957470671
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "control_flow.branch.if.condition.change" ]
97,800
97,801
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
97,802
97,803
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "variable_declaration.array_dimensions.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
97,804
97,803
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "variable_declaration.array_dimensions.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change", "assignment.variable.change", "variable_access.subsc...
97,805
97,803
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
97,806
97,803
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
97,808
97,803
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
97,802
97,811
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "variable_declaration.array_dimensions.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
97,804
97,811
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "variable_declaration.array_dimensions.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change", "assignment.variable.change", "variable_access.subsc...
97,805
97,811
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
97,806
97,811
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "expression.operator.compare.change", "control_flow.branch.if.condition.change", "identifier.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
97,808
97,811
u047988051
cpp
p02249
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
#include <algorithm> #include <cassert> #include <cctype> #include <cstdio> #include <iostream> #include <string> #include <vector> using namespace std; struct AhoCorasick { static const int ALPHABET_SIZE = 62, root = 0; inline int index(char ch) { if (isupper(ch)) return ch - 'A'; if (islower(ch)...
[ "identifier.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change", "assignment.variable.change", "variable_access.subscript.index.change" ]
97,810
97,811
u047988051
cpp
p02249
#include <iostream> using namespace std; #define MOD 10000000000000007LL long long dp[1001][1001]; long long x[1001][1001]; long long y[1001][1001]; long long z[1001]; long long H, W, N, M; long long modpow[1001]; int main() { modpow[0] = 1; for (int i = 1; i <= 1000; i++) { modpow[i] = modpow[i - 1] * 256; ...
#include <iostream> using namespace std; #define MOD 100000000000007LL long long dp[1001][1001]; long long x[1001][1001]; long long y[1001][1001]; long long z[1001]; long long H, W, N, M; long long modpow[1001]; int main() { modpow[0] = 1; for (int i = 1; i <= 1000; i++) { modpow[i] = modpow[i - 1] * 256; m...
[ "preprocessor.define.value.change", "literal.integer.change" ]
97,814
97,813
u852311840
cpp
p02249
#include <bits/stdc++.h> #define base 950527 #define base2 1777771 using namespace std; typedef unsigned long long ll; typedef pair<int, int> P; ll A[1001][1001]; string a[1001], b[1001]; int main() { int W, H, w, h; cin >> H >> W; for (int i = 0; i < H; i++) cin >> a[i]; cin >> h >> w; for (int i = 0; i...
#include <bits/stdc++.h> #define base 950527 #define base2 1777771 using namespace std; typedef unsigned long long ll; typedef pair<int, int> P; ll A[1001][1001]; string a[1001], b[1001]; int main() { int W, H, w, h; cin >> H >> W; for (int i = 0; i < H; i++) cin >> a[i]; cin >> h >> w; for (int i = 0; i...
[ "control_flow.loop.for.initializer.change" ]
97,818
97,819
u952951927
cpp
p02256
#include <algorithm> #include <iostream> using namespace std; int main() { int x, y; cin >> x >> y; if (x < y) { swap(x, y); } while (1) { if (x % y == 0) break; y = x % y; if (x < y) { swap(x, y); } } cout << y << endl; return 0; }
#include <algorithm> #include <iostream> using namespace std; int main() { int x, y; cin >> x >> y; if (x < y) { swap(x, y); } while (1) { if (x % y == 0) break; x = x % y; if (x < y) { swap(x, y); } } cout << y << endl; return 0; }
[ "assignment.variable.change", "identifier.change" ]
97,958
97,959
u442969736
cpp
p02256
#include <algorithm> #include <cstdio> using namespace std; int euclid(int a, int b) { if (b > a) { swap(a, b); } if (a % b == 0) return b; return euclid(a, a % b); } int main() { int x, y; int ans; scanf("%d %d", &x, &y); ans = euclid(x, y); printf("%d\n", ans); return 0; }
#include <algorithm> #include <cstdio> using namespace std; int euclid(int a, int b) { if (b > a) { swap(a, b); } if (a % b == 0) return b; return euclid(b, a % b); } int main() { int x, y; int ans; scanf("%d %d", &x, &y); ans = euclid(x, y); printf("%d\n", ans); return 0; }
[ "identifier.change", "call.arguments.change", "function.return_value.change" ]
97,960
97,961
u423206630
cpp
p02256
#include <iostream> using namespace std; long euclidean(long n, long m) { if (n == m) return n; if (n > m) swap(n, m); return euclidean(m % n, n); } int main() { long n, m; cin >> n >> m; cout << euclidean(n, m) << endl; }
#include <iostream> using namespace std; long euclidean(long n, long m) { if (n == m) return m; if (n > m) swap(n, m); return euclidean(m - n, n); } int main() { long n, m; cin >> n >> m; cout << euclidean(n, m) << endl; }
[ "identifier.change", "function.return_value.change", "expression.operator.arithmetic.change", "call.arguments.change", "expression.operation.binary.change" ]
97,966
97,967
u934356503
cpp
p02256
#include <cmath> #include <iostream> using namespace std; int gcd(int a, int b) { int n = (a < b) ? a : b; if (a % n == 0 && b & n == 0) { return n; } for (int i = sqrt(n); i > 0; --i) { if (a % i == 0 && b % i == 0) { return i; } } } int main(void) { int a, b; cin >> a >> b; cout ...
#include <cmath> #include <iostream> using namespace std; int gcd(int a, int b) { int n = (a < b) ? a : b; if (a % n == 0 && b % n == 0) { return n; } for (int i = n / 2; i > 0; --i) { if (a % i == 0 && b % i == 0) { return i; } } } int main(void) { int a, b; cin >> a >> b; cout <<...
[ "control_flow.branch.if.condition.change", "control_flow.loop.for.initializer.change", "call.remove", "call.arguments.change" ]
97,968
97,969
u105191136
cpp
p02256
#include <cmath> #include <iostream> using namespace std; int gcd(int a, int b) { int n = (a < b) ? a : b; if (a % n == 0 && b & n == 0) { return n; } for (int i = n / 2; i > 0; --i) { if (a % i == 0 && b % i == 0) { return i; } } } int main(void) { int a, b; cin >> a >> b; cout <<...
#include <cmath> #include <iostream> using namespace std; int gcd(int a, int b) { int n = (a < b) ? a : b; if (a % n == 0 && b % n == 0) { return n; } for (int i = n / 2; i > 0; --i) { if (a % i == 0 && b % i == 0) { return i; } } } int main(void) { int a, b; cin >> a >> b; cout <<...
[ "control_flow.branch.if.condition.change" ]
97,970
97,969
u105191136
cpp
p02256
#include <cmath> #include <iostream> using namespace std; int gcd(int a, int b) { int n = (a < b) ? a : b; if (a % n == 0 && b & n == 0) { return n; } cout << n; for (int i = n / 2; i > 0; --i) { if (a % i == 0 && b % i == 0) { return i; } } } int main(void) { int a, b; cin >> a >> ...
#include <cmath> #include <iostream> using namespace std; int gcd(int a, int b) { int n = (a < b) ? a : b; if (a % n == 0 && b % n == 0) { return n; } for (int i = n / 2; i > 0; --i) { if (a % i == 0 && b % i == 0) { return i; } } } int main(void) { int a, b; cin >> a >> b; cout <<...
[ "control_flow.branch.if.condition.change" ]
97,971
97,969
u105191136
cpp
p02256
#include <stdio.h> int main() { int x, y; scanf("%d %d", &x, &y); if (x == y) printf("%d\n", x); else { int z, Z, n, k; if (x < y) z = x, Z = y; else { z = y, Z = x; int r; for (;;) { r = Z % z; if (r == 0) break; Z = z; z = r; ...
#include <stdio.h> int main() { int x, y; scanf("%d %d", &x, &y); if (x == y) printf("%d\n", x); else { int z, Z, n, k; if (x < y) z = x, Z = y; else z = y, Z = x; int r; for (;;) { r = Z % z; if (r == 0) break; Z = z; z = r; } printf(...
[]
97,981
97,982
u192037914
cpp
p02256
#include <iostream> using namespace std; // x > y ??§??????x, y???GCD????±??????? int gcd(int x, int y) { if (y == 0) return x; else return gcd(x, x % y); } int main() { int x, y; cin >> x >> y; if (y > x) swap(x, y); cout << gcd(x, y) << endl; }
#include <iostream> using namespace std; // x > y ??§??????x, y???GCD????±??????? int gcd(long int x, long int y) { if (y == 0) return x; else return gcd(y, x % y); } int main() { long int x, y; cin >> x >> y; if (y > x) swap(x, y); cout << gcd(x, y) << endl; }
[ "variable_declaration.type.widen.change", "identifier.change", "call.arguments.change", "function.return_value.change" ]
97,983
97,984
u114204200
cpp
p02256
#include <iostream> using namespace std; // x > y ??§??????x, y???GCD????±??????? int gcd(long int x, long int y) { if (y == 0) return x; else return gcd(x, x % y); } int main() { long int x, y; cin >> x >> y; if (y > x) swap(x, y); cout << gcd(x, y) << endl; }
#include <iostream> using namespace std; // x > y ??§??????x, y???GCD????±??????? int gcd(long int x, long int y) { if (y == 0) return x; else return gcd(y, x % y); } int main() { long int x, y; cin >> x >> y; if (y > x) swap(x, y); cout << gcd(x, y) << endl; }
[ "identifier.change", "call.arguments.change", "function.return_value.change" ]
97,985
97,984
u114204200
cpp
p02256
#include <algorithm> #include <iostream> int main() { long long a, b, c, d; std::cin >> a >> b; c = a, d = b; if (a < b) std::swap(a, b); while (b != 0) { int r = a % b; a = b; b = r; } std::cout << c * d / a << "\n"; return 0; }
#include <algorithm> #include <iostream> int main() { int a, b, c, d; std::cin >> a >> b; c = a, d = b; if (a < b) std::swap(a, b); while (b != 0) { int r = a % b; a = b; b = r; } std::cout << a << "\n"; return 0; }
[ "variable_declaration.type.primitive.change", "variable_declaration.type.narrow.change", "expression.operation.binary.remove" ]
97,994
97,995
u151928415
cpp
p02256
#include <bits/stdc++.h> using namespace std; int sorts(int *x, int *y) { if (*x < *y) { int temp = *x; *x = *y; *y = temp; } } int main() { int x, y; int ans; cin >> x >> y; while (x != y) { sorts(&x, &y); ans = x - y; x = ans; } cout << ans << endl; }
#include <bits/stdc++.h> using namespace std; int sorts(int *x, int *y) { if (*x < *y) { int temp = *x; *x = *y; *y = temp; } } int main() { int x, y; int ans; cin >> x >> y; while (x != y) { sorts(&x, &y); ans = x - y; x = ans; } cout << x << endl; }
[ "identifier.change", "io.output.change" ]
98,000
98,001
u442166898
cpp
p02256
#include <cstdlib> #include <ctime> #include <iostream> using namespace std; const int NMAX = 10000; void print(int *A, int N) { cout << A[0]; for (int k = 1; k < N; k++) { cout << " " << A[k]; } cout << endl; } int GCD(int x, int y) { if (y == 0) { return x; } else { return GCD(y, x % y); ...
#include <cstdlib> #include <ctime> #include <iostream> using namespace std; const int NMAX = 10000; void print(int *A, int N) { cout << A[0]; for (int k = 1; k < N; k++) { cout << " " << A[k]; } cout << endl; } int GCD(int x, int y) { if (y == 0) { return x; } else { return GCD(y, x % y); ...
[ "assignment.change" ]
98,010
98,011
u184296229
cpp
p02256
#include <bits/stdc++.h> #define GET_MACRO(_1, _2, _3, _4, _5, _6, NAME, ...) NAME #define pr(...) \ cerr << GET_MACRO(__VA_ARGS__, pr6, pr5, pr4, pr3, pr2, pr1)(__VA_ARGS__) \ << endl #define pr1(a) (#a) << "=" << (a) << " " #define pr2(a, b) p...
#include <bits/stdc++.h> #define GET_MACRO(_1, _2, _3, _4, _5, _6, NAME, ...) NAME #define pr(...) \ cerr << GET_MACRO(__VA_ARGS__, pr6, pr5, pr4, pr3, pr2, pr1)(__VA_ARGS__) \ << endl #define pr1(a) (#a) << "=" << (a) << " " #define pr2(a, b) p...
[ "identifier.change", "call.arguments.change", "function.return_value.change" ]
98,144
98,145
u952951927
cpp
p02256
#include <algorithm> #include <iostream> using namespace std; int gcd(int a, int b) { if (a == 1 || b == 1) return max(a, b); else if (max(a, b) % min(a, b) == 0) return min(a, b); else return gcd(min(a, b), (max(a, b)) % (min(a, b))); } int main() { // your code goes here int a, b; cin >> a >...
#include <algorithm> #include <iostream> using namespace std; int gcd(int a, int b) { if (a == 1 || b == 1) return 1; else if (max(a, b) % min(a, b) == 0) return min(a, b); else return gcd(min(a, b), (max(a, b)) % (min(a, b))); } int main() { // your code goes here int a, b; cin >> a >> b; c...
[ "identifier.replace.remove", "literal.replace.add", "function.return_value.change", "call.arguments.change" ]
98,154
98,155
u228579910
cpp
p02256
#include <iostream> using namespace std; int main() { long long x, y, c; cin >> x >> y; if (x < y) { c = y; y = x; x = c; } c = 0; while (!x == 0 || y == 0) { if (c % 2 == 0) { x = x % y; } else { y = y % x; } ++c; } cout << x + y << endl; return 0; }
#include <iostream> using namespace std; int main() { long long x, y, c; cin >> x >> y; if (x < y) { c = y; y = x; x = c; } c = 0; while (x != 0 && y != 0) { if (c % 2 == 0) { x = x % y; } else { y = y % x; } ++c; } cout << x + y << endl; return 0; }
[ "expression.operation.unary.logical.remove", "control_flow.loop.condition.change", "misc.opposites", "expression.operator.compare.change" ]
98,157
98,158
u613278035
cpp
p02256
#include <iostream> #include <stdio.h> using namespace std; int main() { int x, y; int p = 1; int dx; cin >> x >> y; while (1) { dx = x; x = y; y = dx % y; if (y == 0) break; } cout << y << endl; return 0; }
#include <iostream> #include <stdio.h> using namespace std; int main() { int x, y; int p = 1; int dx; cin >> x >> y; while (1) { dx = x; x = y; y = dx % y; if (y == 0) break; } cout << x << endl; return 0; }
[ "identifier.change", "io.output.change" ]
98,161
98,162
u301707458
cpp
p02256
#include <algorithm> #include <iostream> #include <stdio.h> using namespace std; int num = 0; int uclide(int x, int y) { if (y == 0) return x; else { num = x; x = y; y = x % y; uclide(x, y); } } int main() { int x, y; int a = 0; cin >> x; cin >> y; if (x < y) { num = x; x = y...
#include <algorithm> #include <iostream> #include <stdio.h> using namespace std; int num = 0; int uclide(int x, int y) { if (y == 0) return x; else { num = x; x = y; y = num % y; uclide(x, y); } } int main() { int x, y; int a = 0; cin >> x; cin >> y; if (x < y) { num = x; x =...
[ "assignment.value.change", "identifier.change", "expression.operation.binary.change" ]
98,172
98,173
u047399718
cpp
p02256
#include <iostream> using namespace std; int gcd(int n, int m) { if (m == 1 && n % m == 0) return m; else gcd(m, n & m); } int main() { int x, y, g; cin >> x >> y; if (x == y) g = x; else if (x > y) g = gcd(x, y); else g = gcd(y, x); cout << g << endl; return 0; }
#include <iostream> using namespace std; int gcd(int n, int m) { if (n % m == 0) return m; else gcd(m, n % m); } int main() { int x, y, g; cin >> x >> y; if (x == y) g = x; else if (x > y) g = gcd(x, y); else g = gcd(y, x); cout << g << endl; return 0; }
[ "expression.operation.binary.remove", "call.arguments.change", "expression.operation.binary.change" ]
98,176
98,177
u252365561
cpp
p02256
#include <iostream> using namespace std; int gcd(int n, int m) { if (n % m == 0) return m; else gcd(m, n & m); } int main() { int x, y, g; cin >> x >> y; if (x == y) g = x; else if (x > y) g = gcd(x, y); else g = gcd(y, x); cout << g << endl; return 0; }
#include <iostream> using namespace std; int gcd(int n, int m) { if (n % m == 0) return m; else gcd(m, n % m); } int main() { int x, y, g; cin >> x >> y; if (x == y) g = x; else if (x > y) g = gcd(x, y); else g = gcd(y, x); cout << g << endl; return 0; }
[ "call.arguments.change", "expression.operation.binary.change" ]
98,178
98,177
u252365561
cpp
p02256
#include <algorithm> #include <stdio.h> int gcd(int, int); int main() { int x, y, z; scanf("%d, %d\n", x, y); z = gcd(x, y); printf("%d\n", z); return 0; } int gcd(int x, int y) { int r; while (y > 0) { r = x % y; x = y; y = r; } return x; }
#include <algorithm> #include <stdio.h> int gcd(int, int); int main() { int x, y, z; scanf("%d %d", &x, &y); z = gcd(x, y); printf("%d\n", z); return 0; } int gcd(int x, int y) { int r; while (y > 0) { r = x % y; x = y; y = r; } return x; }
[ "literal.string.change", "call.arguments.change", "expression.operation.unary.reference.add" ]
98,179
98,180
u378873972
cpp
p02256
#include <algorithm> #include <stdio.h> int gcd(int, int); int main() { int x, y, z; scanf("%d %d\n", x, y); z = gcd(x, y); printf("%d\n", z); return 0; } int gcd(int x, int y) { int r; while (y > 0) { r = x % y; x = y; y = r; } return x; }
#include <algorithm> #include <stdio.h> int gcd(int, int); int main() { int x, y, z; scanf("%d %d", &x, &y); z = gcd(x, y); printf("%d\n", z); return 0; } int gcd(int x, int y) { int r; while (y > 0) { r = x % y; x = y; y = r; } return x; }
[ "literal.string.change", "call.arguments.change", "expression.operation.unary.reference.add" ]
98,181
98,180
u378873972
cpp
p02256
#include <stdio.h> int main(void) { int x, y, r; scanf("%d %d", &x, &y); if (x > y) { while (y > 0) { r = x % y; x = y; y = r; } printf("%d\n", x); } if (y > x) { while (x > 0) { r = y % x; y = x; x = r; } printf("%d\n", y); } return 0; }
#include <stdio.h> int main(void) { int x, y, r; scanf("%d %d", &x, &y); if (x > y) { while (y > 0) { r = x % y; x = y; y = r; } printf("%d\n", x); } if (y >= x) { while (x > 0) { r = y % x; y = x; x = r; } printf("%d\n", y); } return 0; }
[ "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
98,183
98,184
u443684539
cpp
p02256
#include <iostream> using namespace std; long int gcd(int a, int b) { if (b == 1) return a; return gcd(b, a % b); } int main() { long int x, y; cin >> x >> y; cout << gcd(x, y) << endl; return 0; }
#include <iostream> using namespace std; long int gcd(int a, int b) { if (b == 0) return a; return gcd(b, a % b); } int main() { long int x, y; cin >> x >> y; cout << gcd(x, y) << endl; return 0; }
[ "literal.number.change", "control_flow.branch.if.condition.change" ]
98,191
98,192
u350754611
cpp
p02256
#include <iostream> #include <stdio.h> using namespace std; int gcd(int, int); int main() { int x, y; cin >> x >> y; cout << gcd(x, y) << endl; return 0; } int gcd(int n, int m) { int q, r; if (n < m) { q = n; n = m; m = r; } while (m > 0) { r = n % m; n = m; m = r; } ret...
#include <iostream> #include <stdio.h> using namespace std; int gcd(int, int); int main() { int x, y; cin >> x >> y; cout << gcd(x, y) << endl; return 0; } int gcd(int n, int m) { int q, r; if (n < m) { q = n; n = m; m = q; } while (m > 0) { r = n % m; n = m; m = r; } ret...
[ "assignment.value.change", "identifier.change" ]
98,193
98,194
u470328896
cpp
p02256
#include <iostream> #define INPUT_FROM_FILE (1) #if INPUT_FROM_FILE #include <fstream> #endif int gcd(int a, int b) { if (a % b == 0) { return b; } return gcd(b, a % b); } int main(int argc, char **argv) { #if INPUT_FROM_FILE std::ifstream ifs("test.txt"); #endif int a = 0; int b = 0; #if INPUT_FROM...
#include <iostream> #define INPUT_FROM_FILE (0) #if INPUT_FROM_FILE #include <fstream> #endif int gcd(int a, int b) { if (a % b == 0) { return b; } return gcd(b, a % b); } int main(int argc, char **argv) { #if INPUT_FROM_FILE std::ifstream ifs("test.txt"); #endif int a = 0; int b = 0; #if INPUT_FROM...
[ "preprocessor.define.value.change", "literal.integer.change" ]
98,204
98,205
u148628801
cpp
p02256
#include <iostream> int main() { int x, y, p, q; bool switching = true; std::cin >> x >> y; if (x > y) { while (true) { if (switching) { p = y; q = x % y; switching = false; if (q == 0) { std::cout << y << "\n"; return 0; } } else { ...
#include <iostream> int main() { int x, y, p, q; bool switching = true; std::cin >> x >> y; if (x >= y) { while (true) { if (switching) { p = y; q = x % y; switching = false; if (q == 0) { std::cout << y << "\n"; return 0; } } else { ...
[ "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
98,206
98,207
u544156467
cpp
p02256
#include <stdio.h> int gcd(int x, int y) { return (x % y > 0 || x > y) ? gcd(y, x % y) : y; } int main() { int x, y; int w; scanf("%d %d", &x, &y); w = gcd(x, y); printf("%d\n", w); }
#include <stdio.h> int gcd(int x, int y) { return (x % y > 0) ? gcd(y, x % y) : y; } int main() { int x, y; int w; scanf("%d %d", &x, &y); w = gcd(x, y); printf("%d\n", w); }
[ "expression.operation.binary.remove" ]
98,210
98,211
u239471853
cpp
p02256
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { a = a % b; a = b; b = c; } cout << c << "\n"; return 0; }
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { c = a % b; a = b; b = c; } cout << b << "\n"; }
[ "assignment.variable.change", "identifier.change", "io.output.change" ]
98,230
98,231
u883196454
cpp
p02256
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { a = a % b; a = b; b = c; } cout << c << "\n"; }
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { c = a % b; a = b; b = c; } cout << b << "\n"; }
[ "assignment.variable.change", "identifier.change", "io.output.change" ]
98,232
98,231
u883196454
cpp
p02256
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { c = a % b; a = b; b = c; } cout << c << "\n"; return 0; }
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { c = a % b; a = b; b = c; } cout << b << "\n"; }
[ "identifier.change", "io.output.change" ]
98,233
98,231
u883196454
cpp
p02256
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { c = a % b; a = b; b = c; } cout << c << "\n"; }
#include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; while (a % b != 0) { c = a % b; a = b; b = c; } cout << b << "\n"; }
[ "identifier.change", "io.output.change" ]
98,234
98,231
u883196454
cpp
p02256
#include <iostream> class CommonDivisor { private: unsigned int x; unsigned int y; public: CommonDivisor(int x, int y); int getMaxCommonDivisor(); }; CommonDivisor::CommonDivisor(int x, int y) { this->x = x; this->y = y; } int CommonDivisor::getMaxCommonDivisor() { if (x < y) { unsigned int tmp =...
#include <iostream> class CommonDivisor { private: unsigned int x; unsigned int y; public: CommonDivisor(int x, int y); int getMaxCommonDivisor(); }; CommonDivisor::CommonDivisor(int x, int y) { this->x = x; this->y = y; } int CommonDivisor::getMaxCommonDivisor() { if (x < y) { unsigned int tmp =...
[ "variable_declaration.value.change", "identifier.change" ]
98,239
98,240
u437211664
cpp
p02256
#include <iostream> int gcd(int x, int y) { if (x % y == 0) { return x; } else { gcd(y, x % y); } } int main() { int x, y, swp; std::cin >> x >> y; if (x < y) { swp = x; x = y; y = x; } std::cout << gcd(x, y) << std::endl; return 0; }
#include <iostream> int gcd(int x, int y) { if (x % y == 0) { return y; } else { gcd(y, x % y); } } int main() { int x, y, swp; std::cin >> x >> y; if (x < y) { swp = x; x = y; y = swp; } std::cout << gcd(x, y) << std::endl; return 0; }
[ "identifier.change", "function.return_value.change", "assignment.value.change" ]
98,254
98,255
u790463499
cpp
p02256
#include <iostream> int gcd(int x, int y) { if (x % y == 0) { return y; } else { gcd(y, x % y); } } int main() { int x, y, swp; std::cin >> x >> y; if (x < y) { swp = x; x = y; y = x; } std::cout << gcd(x, y) << std::endl; return 0; }
#include <iostream> int gcd(int x, int y) { if (x % y == 0) { return y; } else { gcd(y, x % y); } } int main() { int x, y, swp; std::cin >> x >> y; if (x < y) { swp = x; x = y; y = swp; } std::cout << gcd(x, y) << std::endl; return 0; }
[ "assignment.value.change", "identifier.change" ]
98,256
98,255
u790463499
cpp
p02256
#include <bits/stdc++.h> #include <ctype.h> #include <math.h> using namespace std; #define FOR(i, a, n) for (int i = a; i < n; i++) #define REP(i, n) for (int i = 0; i < n; i++) struct omt { omt() { ios::sync_with_stdio(false); cin.tie(0); } } star; int main() { int x, y; cin >> x >> y; if (x < y) {...
#include <bits/stdc++.h> #include <ctype.h> #include <math.h> using namespace std; #define FOR(i, a, n) for (int i = a; i < n; i++) #define REP(i, n) for (int i = 0; i < n; i++) struct omt { omt() { ios::sync_with_stdio(false); cin.tie(0); } } star; int main() { int x, y; cin >> x >> y; if (x < y) {...
[ "assignment.value.change", "identifier.change" ]
98,531
98,532
u855694108
cpp
p02256
#include <algorithm> #include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; if (b > a) swap(a, b); while (a != b) { c = a - b; a = b; b = c; if (b > a) swap(a, b); } cout << c << endl; return 0; }
#include <algorithm> #include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; if (b > a) swap(a, b); while (a != b) { c = a - b; a = b; b = c; if (b > a) swap(a, b); } cout << b << endl; return 0; }
[ "identifier.change", "io.output.change" ]
98,540
98,541
u355694759
cpp
p02256
#include <algorithm> #include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; if (b > a) swap(a, b); while (b > 0) { c = a % b; a = b; b = c; } cout << b << endl; return 0; }
#include <algorithm> #include <iostream> using namespace std; int main() { int a, b, c; cin >> a >> b; if (b > a) swap(a, b); while (b > 0) { c = a % b; a = b; b = c; } cout << a << endl; return 0; }
[ "identifier.change", "io.output.change" ]
98,542
98,543
u355694759
cpp
p02256
#include <stdio.h> int main(void) { int x; int y; int r; int tmp; scanf("%d %d", &x, &y); if (y >= x) { x = tmp; x = y; y = tmp; } while (1) { r = x % y; if (r == 0) { printf("%d\n", y); break; } x = y; y = r; } return 0; }
#include <stdio.h> int main(void) { int x; int y; int r; int tmp; scanf("%d %d", &x, &y); if (y >= x) { tmp = x; x = y; y = tmp; } while (1) { r = x % y; if (r == 0) { printf("%d\n", y); break; } x = y; y = r; } return 0; }
[ "assignment.change" ]
98,547
98,548
u349721971
cpp
p02256
#include <algorithm> #include <iostream> using namespace std; // x,yの最大公約数を求める int main() { int x, y, big, small, amari; cin >> x >> y; big = max(x, y), small = min(x, y); //ユークリッドの互除法 while (big % small != 0) { //余り0で終了 amari = big % small; big = move(small); small = move(amari); } cout ...
#include <algorithm> #include <iostream> using namespace std; // x,yの最大公約数を求める int main() { int x, y, big, small; cin >> x >> y; big = max(x, y), small = min(x, y); //ユークリッドの互除法 while (big % small != 0) { //余り0で終了 int amari = big % small; big = move(small); small = move(amari); } cout << ...
[ "variable_declaration.remove", "identifier.change", "io.output.change" ]
98,551
98,552
u951250295
cpp
p02256
#include <iostream> #include <vector> using namespace std; int main() { int a, b; cin >> a >> b; if (b > a) { auto tmp = a; a = b; b = a; } // post: a >= b while (b != 0) { auto tmp = a % b; a = b; b = tmp; } cout << a << endl; }
#include <iostream> #include <vector> using namespace std; int main() { int a, b; cin >> a >> b; if (b > a) { auto tmp = a; a = b; b = tmp; } // post: a >= b while (b != 0) { auto tmp = a % b; a = b; b = tmp; } cout << a << endl; }
[ "assignment.value.change", "identifier.change" ]
98,563
98,564
u652366248
cpp
p02256
#include <iostream> using namespace std; int gcd(int a, int b) { if (b == 0) return a; else return gcd(b, a % b); } int main(void) { int a, b, c; cin >> a >> b; if (a < b) { c = a; a = b; b = a; } cout << gcd(a, b) << endl; return 0; }
#include <iostream> using namespace std; int gcd(int a, int b) { if (b == 0) return a; else return gcd(b, a % b); } int main(void) { int a, b, c; cin >> a >> b; if (a < b) { c = a; a = b; b = c; } cout << gcd(a, b) << endl; return 0; }
[ "assignment.value.change", "identifier.change" ]
98,565
98,566
u473115569
cpp
p02256
#include <stdio.h> int main() { int x, y, temp; scanf("%d %d", &x, &y); if (x < y) { temp = x; y = x; x = temp; } while ((x % y) != 0) { temp = y; y = x % y; x = temp; } printf("%d\n", y); return 0; }
#include <stdio.h> int main() { int x, y, temp; scanf("%d %d", &x, &y); if (x < y) { temp = y; y = x; x = temp; } while ((x % y) != 0) { temp = y; y = x % y; x = temp; } printf("%d\n", y); return 0; }
[ "assignment.value.change", "identifier.change" ]
98,588
98,589
u170658813
cpp
p02256
#include <stdio.h> main() { long d = 1; long a, b, c; scanf("%d %d", &a, &b); if (b > a) { c = a; a = b; b = c; } while (d != 0) { d = a % b; a = b; b = d; } printf("%ld", a); }
#include <stdio.h> main() { long d = 1; long a, b, c; scanf("%ld %ld", &a, &b); if (b > a) { c = a; a = b; b = c; } while (d != 0) { d = a % b; a = b; b = d; } printf("%ld\n", a); }
[ "literal.string.change", "call.arguments.change", "io.output.change", "io.output.newline.add" ]
98,597
98,595
u680906409
cpp
p02256
#include <stdio.h> main() { long d; long a, b, c; scanf("%d %d", &a, &b); if (b > a) { c = a; a = b; b = c; } while (d != 0) { d = a % b; a = b; b = d; } printf("%ld", a); }
#include <stdio.h> main() { long d = 1; long a, b, c; scanf("%ld %ld", &a, &b); if (b > a) { c = a; a = b; b = c; } while (d != 0) { d = a % b; a = b; b = d; } printf("%ld\n", a); }
[ "variable_declaration.value.change", "literal.string.change", "call.arguments.change", "io.output.change", "io.output.newline.add" ]
98,598
98,595
u680906409
cpp
p02256
#include <stdio.h> main() { long d; long a, b, c; scanf("%ld %ld", &a, &b); if (b > a) { c = a; a = b; b = c; } while (d != 0) { d = a % b; a = b; b = d; } printf("%ld", a); }
#include <stdio.h> main() { long d = 1; long a, b, c; scanf("%ld %ld", &a, &b); if (b > a) { c = a; a = b; b = c; } while (d != 0) { d = a % b; a = b; b = d; } printf("%ld\n", a); }
[ "variable_declaration.value.change", "literal.string.change", "call.arguments.change", "io.output.change", "io.output.newline.add" ]
98,599
98,595
u680906409
cpp
p02257
#include <bits/stdc++.h> using namespace std; bool isprime(int x) { if (x == 2) return true; if (x < 2 || x % 2 == 0) return false; for (int i = 3; i * i < x; i += 2) { if (x % i == 0) return false; } return true; } int main() { int n, x; int cnt = 0; cin >> n; for (int i = 0; i...
#include <bits/stdc++.h> using namespace std; bool isprime(int x) { if (x == 2) return true; if (x < 2 || x % 2 == 0) return false; for (int i = 3; i * i <= x; i += 2) { if (x % i == 0) return false; } return true; } int main() { int n, x; int cnt = 0; cin >> n; for (int i = 0; ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,167
99,168
u354867116
cpp
p02257
#include <cmath> #include <ctype.h> #include <iomanip> #include <iostream> #include <stdio.h> #include <string.h> using namespace std; int main(void) { int n, a, b, count, c, w; double d; n = 0; b = 0; cin >> n; // cout<<"n="<<n<<endl; count = 0; for (a = 0; a < n; a++) { cin >> b; d = b; ...
#include <cmath> #include <ctype.h> #include <iomanip> #include <iostream> #include <stdio.h> #include <string.h> using namespace std; int main(void) { int n, a, b, count, c, w; double d; n = 0; b = 0; cin >> n; // cout<<"n="<<n<<endl; count = 0; for (a = 0; a < n; a++) { cin >> b; d = b; ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.operation.binary.change" ]
99,169
99,170
u172520305
cpp
p02257
#include <cmath> #include <cstdio> #define rep(i, n) for (int(i) = 0; (i) < (n); (i)++) int isPrime(int m) { if (m == 2) return true; if (m <= 1) return false; if (m % 2 == 0) return false; int i = 3; while (i < sqrt(m)) { if (m % i == 0) return false; i++; } return true; } in...
#include <cmath> #include <cstdio> #define rep(i, n) for (int(i) = 0; (i) < (n); (i)++) int isPrime(int m) { if (m == 2) return true; if (m <= 1) return false; if (m % 2 == 0) return false; int i = 3; while (i <= sqrt(m)) { if (m % i == 0) return false; i++; } return true; } i...
[ "expression.operator.compare.change", "control_flow.loop.condition.change" ]
99,171
99,172
u878584486
cpp
p02257
#include <iostream> static bool is_prime(long n) { static long p[10000] = {2l}; static int ip = 1; for (int i = 0; i < ip; ++i) { if (n == p[i]) { return true; } } if (n % 2l == 0l) { return false; } for (long i = 3l; i * i < n; i += 2l) { if (n % i == 0l) { return false; }...
#include <iostream> static bool is_prime(long n) { static long p[10000] = {2l}; static int ip = 1; for (int i = 0; i < ip; ++i) { if (n == p[i]) { return true; } } if (n % 2l == 0l) { return false; } for (long i = 3l; i * i <= n; i += 2l) { if (n % i == 0l) { return false; ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,174
99,175
u529602958
cpp
p02257
#include <cmath> #include <iostream> using namespace std; bool is_prime(int x) { if (x == 2) { return true; } else if (x < 2 || x % 2 == 0) { return false; } for (int i = 3; i < sqrt(x); i += 2) { if (x % i == 0) { return false; } } return true; } int main() { int n; cin >> n; ...
#include <cmath> #include <iostream> using namespace std; bool is_prime(int x) { if (x == 2) { return true; } else if (x < 2 || x % 2 == 0) { return false; } for (int i = 3; i <= sqrt(x); i += 2) { if (x % i == 0) { return false; } } return true; } int main() { int n; cin >> n; ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,176
99,177
u972675635
cpp
p02257
#include <algorithm> #include <cmath> #include <iostream> #include <vector> using namespace std; bool isprime(int x) { if (x == 2) { return true; } else if (x % 2 == 0) { return false; } int i = 3; while (i <= sqrt(x)) { if (x % i == 0) { return false; } i = i + 2; } } int main() ...
#include <algorithm> #include <cmath> #include <iostream> #include <vector> using namespace std; bool isprime(int x) { if (x == 2) { return true; } else if (x % 2 == 0) { return false; } int i = 3; while (i <= sqrt(x)) { if (x % i == 0) { return false; break; } i = i + 2; } ...
[ "control_flow.break.add", "control_flow.return.add" ]
99,181
99,182
u442969736
cpp
p02257
#include <algorithm> #include <cmath> #include <iostream> #include <vector> using namespace std; bool isprime(int x) { if (x == 2) { return true; } else if (x % 2 == 0) { return false; } int i = 3; while (i <= sqrt(x)) { if (x % i == 0) { return false; } i = i + 2; return true; ...
#include <algorithm> #include <cmath> #include <iostream> #include <vector> using namespace std; bool isprime(int x) { if (x == 2) { return true; } else if (x % 2 == 0) { return false; } int i = 3; while (i <= sqrt(x)) { if (x % i == 0) { return false; break; } i = i + 2; } ...
[ "control_flow.break.add" ]
99,183
99,182
u442969736
cpp
p02257
#include <cmath> #include <iostream> using namespace std; bool sosu(int n) { if (n < 2) return false; // 2以下除く else if (n == 2) return true; // 2は素数 else if (n % 2 == 0) return false; //偶数除く int root = sqrt(n); for (int i = 3; i < root; i += 2) { //奇数で割る if (n % i == 0) return false; ...
#include <cmath> #include <iostream> using namespace std; bool sosu(int n) { if (n < 2) return false; // 2以下除く else if (n == 2) return true; // 2は素数 else if (n % 2 == 0) return false; //偶数除く int root = sqrt(n); for (int i = 3; i <= root; i += 2) { //奇数で割る if (n % i == 0) return false; ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,186
99,187
u558461198
cpp
p02257
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int cnt = 0; for (int i = 0; i < n; i++) { int a; cin >> a; a = sqrt(a); for (int j = 2; j < a; j++) { if (a % j == 0) { cnt++; break; } } } cout << n - cnt << endl; return 0; }...
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int cnt = 0; for (int i = 0; i < n; i++) { int a; cin >> a; int t = sqrt(a); for (int j = 2; j <= t; j++) { if (a % j == 0) { cnt++; break; } } } cout << n - cnt << endl; return...
[ "control_flow.loop.for.condition.change" ]
99,189
99,190
u407273977
cpp
p02257
#include <cmath> #include <iostream> using namespace std; int main() { // def int n, j, sum = 0; cin >> n; int num[n]; for (int i = 0; i < n; i++) { cin >> num[i]; } // equation for (int i = 0; i < n; i++) { for (j = 2; j < sqrt(num[i]); j++) { if (num[i] % j == 0) { break; ...
#include <cmath> #include <iostream> using namespace std; int main() { // def int n, j, sum = 0; cin >> n; int num[n]; for (int i = 0; i < n; i++) { cin >> num[i]; } // equation for (int i = 0; i < n; i++) { for (j = 2; j < sqrt(num[i]); j++) { if (num[i] % j == 0) { break; ...
[ "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
99,191
99,192
u712985670
cpp
p02257
#include <cmath> #include <iostream> using namespace std; int main() { // def int n, j, sum = 0; cin >> n; int num[n]; for (int i = 0; i < n; i++) { cin >> num[i]; } // equation for (int i = 0; i < n; i++) { for (j = 2; j < sqrt(num[i]); j++) { if (num[i] % j == 0) { break; ...
#include <cmath> #include <iostream> using namespace std; int main() { // def int n, j, sum = 0; cin >> n; int num[n]; for (int i = 0; i < n; i++) { cin >> num[i]; } // equation for (int i = 0; i < n; i++) { for (j = 2; j < sqrt(num[i]); j++) { if (num[i] % j == 0) { break; ...
[ "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
99,193
99,192
u712985670
cpp
p02257
#include <cmath> #include <iostream> using namespace std; int main() { // def int n, j, sum = 0; cin >> n; int num[n]; for (int i = 0; i < n; i++) { cin >> num[i]; } // equation for (int i = 0; i < n; i++) { for (j = 2; j < sqrt(num[i]); j++) { if (num[i] % j == 0) { break; ...
#include <cmath> #include <iostream> using namespace std; int main() { // def int n, j, sum = 0; cin >> n; int num[n]; for (int i = 0; i < n; i++) { cin >> num[i]; } // equation for (int i = 0; i < n; i++) { for (j = 2; j < sqrt(num[i]); j++) { if (num[i] % j == 0) { break; ...
[ "misc.opposites", "expression.operator.compare.change", "control_flow.branch.if.condition.change" ]
99,194
99,192
u712985670
cpp
p02257
#include <cmath> #include <iostream> using namespace std; bool isPrime(int x) { if (x == 2) { return true; } if (x == 1 || x % 2 == 0) { return false; } for (int i = 3; i < sqrt(x); i++) { if (x % i == 0) { return false; } } return true; } int main() { int N; cin >> N; int...
#include <cmath> #include <iostream> using namespace std; bool isPrime(int x) { if (x == 2) { return true; } if (x == 1 || x % 2 == 0) { return false; } for (int i = 3; i < sqrt(x) + 1; i++) { if (x % i == 0) { return false; } } return true; } int main() { int N; cin >> N; ...
[ "control_flow.loop.for.condition.change", "misc.off_by_one" ]
99,195
99,196
u229973939
cpp
p02257
#include <cmath> #include <iostream> using namespace std; int main(void) { int n; int a; int count = 0; cin >> n; for (int i = 0; i < n; ++i) { bool check = true; cin >> a; for (int j = 2; j < sqrt(a); ++j) { if (a % i == 0) { check = false; } } if (check) ++cou...
#include <cmath> #include <iostream> using namespace std; int main(void) { int n; int a; int count = 0; cin >> n; for (int i = 0; i < n; ++i) { bool check = true; cin >> a; for (int j = 2; j <= sqrt(a); ++j) { if (a % j == 0) { check = false; } } if (check) ++co...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change", "identifier.change", "control_flow.branch.if.condition.change" ]
99,199
99,200
u105191136
cpp
p02257
#include <cmath> #include <iostream> using namespace std; int main(void) { int n; int a; int count = 0; cin >> n; for (int i = 0; i < n; ++i) { bool check = true; cin >> a; for (int j = 2; j < sqrt(a); ++j) { if (a % j == 0) { check = false; } } if (check) ++cou...
#include <cmath> #include <iostream> using namespace std; int main(void) { int n; int a; int count = 0; cin >> n; for (int i = 0; i < n; ++i) { bool check = true; cin >> a; for (int j = 2; j <= sqrt(a); ++j) { if (a % j == 0) { check = false; } } if (check) ++co...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,201
99,200
u105191136
cpp
p02257
#include <iostream> #include <math.h> #define N 10000 using namespace std; int isprime(int); int main() { int i, n, x, count = 0; cin >> n; for (i = 0; i < n; i++) { cin >> x; count += isprime(x); } cout << count << endl; return 0; } int isprime(int x) { if (x == 2) return 1; else i...
#include <iostream> #include <math.h> #define N 10000 using namespace std; int isprime(int); int main() { int i, n, x, count = 0; cin >> n; for (i = 0; i < n; i++) { cin >> x; count += isprime(x); } cout << count << endl; return 0; } int isprime(int x) { if (x == 2) return 1; else i...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,203
99,204
u225502267
cpp
p02257
#include <cmath> #include <iostream> #include <vector> using namespace std; void fnPrimeNumber(const vector<int> &argviNum, int &argiPrimeCnt) { for (int i = 0; i < argviNum.size(); i++) { double dSqrt = sqrt((double)argviNum[i]); int iMaxDivisor = (int)dSqrt; bool bPrime = true; for (int iDivisor =...
#include <cmath> #include <iostream> #include <vector> using namespace std; void fnPrimeNumber(const vector<int> &argviNum, int &argiPrimeCnt) { for (int i = 0; i < argviNum.size(); i++) { double dSqrt = sqrt((double)argviNum[i]); int iMaxDivisor = (int)dSqrt; bool bPrimeNo = true; for (int iDivisor...
[ "variable_declaration.name.change", "identifier.change", "control_flow.branch.if.condition.change" ]
99,207
99,208
u050764167
cpp
p02257
#include <cmath> #include <iostream> using namespace std; bool checkNotOdd(int n) { if (n % 2 == 0) { return false; } else { return true; } } bool check(int n) { for (int i = 2; i < sqrt(n); i++) { if (n % i == 0) { return false; } } return true; } int main() { int n; cin >> n; ...
#include <cmath> #include <iostream> using namespace std; bool checkNotOdd(int n) { if (n % 2 == 0) { return false; } else { return true; } } bool check(int n) { for (int i = 2; i <= sqrt(n); i++) { if (n % i == 0) { return false; } } return true; } int main() { int n; cin >> n; ...
[ "expression.operator.compare.change", "control_flow.loop.for.condition.change", "expression.off_by_one", "expression.operation.binary.change" ]
99,209
99,210
u910472179
cpp