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 |
|---|---|---|---|---|---|---|---|
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int N, D;
cin >> N >> D;
int ans = 0;
for (int i = 0; i < N; i++) {
int X, Y;
cin >> X >> Y;
if (sqrt(X * X + Y * Y) <= D) {
ans++;
}
}
cout << ans << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int64_t N, D;
cin >> N >> D;
int ans = 0;
for (int i = 0; i < N; i++) {
int64_t X, Y;
cin >> X >> Y;
if (sqrt(X * X + Y * Y) <= D) {
ans++;
}
}
cout << ans << endl;
} | [
"variable_declaration.type.primitive.change"
] | 296,055 | 296,056 | u453366189 | cpp |
p02595 | #include <algorithm>
#include <assert.h>
#include <bitset>
#include <cassert>
#include <cctype>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstdio>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
... | #include <algorithm>
#include <assert.h>
#include <bitset>
#include <cassert>
#include <cctype>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstdio>
#include <ctime>
#include <deque>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
... | [
"variable_declaration.type.change",
"control_flow.loop.for.initializer.change"
] | 296,057 | 296,058 | u605833494 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
long long int n, d;
cin >> n >> d;
long long int res = 0;
while (n--) {
long long int p, q;
cin >> p >> q;
if (((p * p) + (q * q)) == (d * d)) {
res++;
}
}
cout << res;
r... | #include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
long long int n, d;
cin >> n >> d;
long long int res = 0;
while (n--) {
long long int p, q;
cin >> p >> q;
if (((p * p) + (q * q)) <= (d * d)) {
res++;
}
}
cout << res;
r... | [
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,059 | 296,060 | u343571251 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
struct edge {
int to;
ll cost;
};
int dx[] = {-1, 1, 0, 0};
int dy[] = {0, 0, 1, -1};
ll GCD(ll a, ll b) {
if (b == 0)
return a;
else
return GCD(b, a % b);
}
ll LCM(ll a, ll b) {
if (a < b)
swap(a, b... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
struct edge {
int to;
ll cost;
};
int dx[] = {-1, 1, 0, 0};
int dy[] = {0, 0, 1, -1};
ll GCD(ll a, ll b) {
if (b == 0)
return a;
else
return GCD(b, a % b);
}
ll LCM(ll a, ll b) {
if (a < b)
swap(a, b... | [
"variable_declaration.type.change"
] | 296,061 | 296,062 | u051393148 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
typedef pair<int, int> ii;
int n, d;
int ans;
int main() {
scanf("%d%d", &n, &d);
for (int i = 0; i < n; i++) {
int x, y;
scanf("%d%d", &x, &y);
double cur = sqrt(x * x + y * y);
if (cur <= d)
ans++;
}
printf("%d\n", ans);
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
typedef pair<int, int> ii;
int n, d;
int ans;
int main() {
scanf("%d%d", &n, &d);
for (int i = 0; i < n; i++) {
long long x, y;
scanf("%lld%lld", &x, &y);
double cur = sqrt(x * x + y * y);
if (cur <= d)
ans++;
}
printf("%d\n", ans);
return... | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change",
"literal.string.change",
"call.arguments.change"
] | 296,067 | 296,068 | u401171259 | cpp |
p02595 | #include <algorithm> //next_permutation
#include <cctype> //文字の判定
#include <cmath> //min,max
#include <complex>
#include <iomanip>
#include <iostream> //swap(#inc<utility>より)
#include <locale>
#include <map> //map
#include <math.h> //要ります?
#include <queue>
#include <random>
#include <set>
#include <sstream>
#... | #include <algorithm> //next_permutation
#include <cctype> //文字の判定
#include <cmath> //min,max
#include <complex>
#include <iomanip>
#include <iostream> //swap(#inc<utility>より)
#include <locale>
#include <map> //map
#include <math.h> //要ります?
#include <queue>
#include <random>
#include <set>
#include <sstream>
#... | [
"variable_declaration.type.change"
] | 296,069 | 296,070 | u742306624 | cpp |
p02595 | #include "bits/stdc++.h"
using namespace std;
template <class... Args> void gin(Args &&...args) { (cin >> ... >> args); }
#define dbg(var) cout << #var << "=" << var << " "
#define nl cout << "\n"
#define fr(i, n) for (int i = 0; i < n; i++)
#define rep(i, a, n) for (int i = a; i <= n; i++)
#define vi vector<int>
#def... | #include "bits/stdc++.h"
using namespace std;
template <class... Args> void gin(Args &&...args) { (cin >> ... >> args); }
#define dbg(var) cout << #var << "=" << var << " "
#define nl cout << "\n"
#define fr(i, n) for (int i = 0; i < n; i++)
#define rep(i, a, n) for (int i = a; i <= n; i++)
#define vi vector<int>
#def... | [] | 296,071 | 296,072 | u292011786 | cpp |
p02595 | #include <algorithm>
#include <cmath>
#include <iostream>
#include <vector>
using namespace std;
using ll = long long;
int main() {
int n;
int d;
cin >> n >> d;
int x, y;
int cnt = 0;
for (int i = 0; i < n; i++) {
cin >> x >> y;
if (d * d >= (x * x + y * y))
cnt++;
}
cout << cnt;
} | #include <algorithm>
#include <cmath>
#include <iostream>
#include <vector>
using namespace std;
using ll = long long;
int main() {
int n;
ll d;
cin >> n >> d;
ll x, y;
int cnt = 0;
for (int i = 0; i < n; i++) {
cin >> x >> y;
if (d * d >= (x * x + y * y))
cnt++;
}
cout << cnt;
} | [
"variable_declaration.type.change"
] | 296,073 | 296,074 | u855186748 | cpp |
p02595 | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
// datatypes
#define ll long long
#define vi vector<int>
#define vll vector<ll>
#define si set<int>
#define vii vector<ii>
#define ii pair<int, int>
#define vpll vector... | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace std;
using namespace __gnu_pbds;
// datatypes
#define ll long long
#define vi vector<int>
#define vll vector<ll>
#define si set<int>
#define vii vector<ii>
#define ii pair<int, int>
#define vpll vector... | [] | 296,075 | 296,076 | u691045386 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int n, d;
cin >> n >> d;
d *= d;
int sum = 0;
while (n--) {
long long x, y;
cin >> x >> y;
if (x * x + y * y <= d)
sum++;
}
cout << sum;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
long long n, d;
cin >> n >> d;
d *= d;
int sum = 0;
while (n--) {
long long x, y;
cin >> x >> y;
if (x * x + y * y <= d)
sum++;
}
cout << sum;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change"
] | 296,079 | 296,080 | u371958417 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pll = pair<ll, ll>;
using vl = vector<ll>;
using vvl = vector<vector<ll>>;
/* short */
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define Fi first
#define Se second
#define ALL(v) begin(v), end(v)
#define RALL(v) rbegin(v)... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pll = pair<ll, ll>;
using vl = vector<ll>;
using vvl = vector<vector<ll>>;
/* short */
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define Fi first
#define Se second
#define ALL(v) begin(v), end(v)
#define RALL(v) rbegin(v)... | [] | 296,081 | 296,082 | u790171360 | cpp |
p02595 | #include <stdio.h>
typedef long long ll;
int main(void) {
ll n, d, i, ans = 0;
scanf("%lld %lld", &n, &d);
while (n--) {
ll p, q;
scanf("%lld %lld", &p, &q);
if (p * p + q * q >= d * d)
ans++;
}
printf("%lld", ans);
return 0;
} | #include <stdio.h>
typedef long long ll;
int main(void) {
ll n, d, i, ans = 0;
scanf("%lld %lld", &n, &d);
while (n--) {
ll p, q;
scanf("%lld %lld", &p, &q);
if (p * p + q * q <= d * d)
ans++;
}
printf("%lld", ans);
return 0;
} | [
"misc.opposites",
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,083 | 296,084 | u211544300 | cpp |
p02595 | /**
* The man who codes no bugs
* McCheng is the man studying Maths in CUHK with IQ200
* @author McCheng
*/
#include <bits/stdc++.h>
using namespace std;
#define int long long
class BDistance {
public:
static constexpr int kStressCount = 0;
static void generateTest(ostream &test) {}
void solve(istream &cin, ... | /**
* The man who codes no bugs
* McCheng is the man studying Maths in CUHK with IQ200
* @author McCheng
*/
#include <bits/stdc++.h>
using namespace std;
#define int long long
class BDistance {
public:
static constexpr int kStressCount = 0;
static void generateTest(ostream &test) {}
void solve(istream &cin, ... | [
"control_flow.branch.if.condition.change",
"control_flow.loop.for.condition.change"
] | 296,089 | 296,090 | u005179181 | cpp |
p02595 | #include <algorithm>
#include <cmath>
#include <cstring>
#include <iomanip>
#include <iostream>
#include <limits>
#include <map>
#include <queue>
#include <vector>
#define rep(i, n) for (int i = 0; i < n; i++)
#define rep1(i, n) for (int i = 1; i <= n; i++)
const int INF = 1e6;
using namespace std;
using ll = long long... | #include <algorithm>
#include <cmath>
#include <cstring>
#include <iomanip>
#include <iostream>
#include <limits>
#include <map>
#include <queue>
#include <vector>
#define rep(i, n) for (int i = 0; i < n; i++)
#define rep1(i, n) for (int i = 1; i <= n; i++)
const int INF = 1e6;
using namespace std;
using ll = long long... | [
"variable_declaration.type.change"
] | 296,091 | 296,092 | u556774846 | cpp |
p02595 | #include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); i++)
#define RREP(i, s, n) for (int i = s; i < (n); i++)
#define ALL(a) a.begin(), a.end()
#define RALL(a) a.rbegin(), a.rend()
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return 1;
}
return 0;
}
template <class ... | #include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < (n); i++)
#define RREP(i, s, n) for (int i = s; i < (n); i++)
#define ALL(a) a.begin(), a.end()
#define RALL(a) a.rbegin(), a.rend()
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return 1;
}
return 0;
}
template <class ... | [
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,093 | 296,094 | u538125576 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
/* useful defines with short names */
#define st first
#define nd second
#define pb push_back
#define pp pop_back
#define all(x) (x).begin(), (x).end()
#define lb(a, b, c) lower_bound(a, b, c)
#define ub(a, b, c) upper_bound(a, b, c)
#define forn(i, n) for (int i = 0; i < ... | #include <bits/stdc++.h>
using namespace std;
/* useful defines with short names */
#define st first
#define nd second
#define pb push_back
#define pp pop_back
#define all(x) (x).begin(), (x).end()
#define lb(a, b, c) lower_bound(a, b, c)
#define ub(a, b, c) upper_bound(a, b, c)
#define forn(i, n) for (int i = 0; i < ... | [
"control_flow.branch.if.condition.change"
] | 296,095 | 296,096 | u373182806 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int n, k, a, b, sum = 0;
cin >> n >> k;
for (int i = 0; i < n; i++) {
cin >> a >> b;
if (sqrt(a * a + b * b) <= k)
sum++;
}
cout << sum << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
double n, k, a, b, sum = 0;
cin >> n >> k;
for (int i = 0; i < n; i++) {
cin >> a >> b;
if (sqrt(a * a + b * b) <= k)
sum++;
}
cout << sum << endl;
return 0;
} | [
"variable_declaration.type.primitive.change"
] | 296,097 | 296,098 | u376384497 | cpp |
p02595 | #include <iostream>
#include <string>
using namespace std;
int main() {
int c, distance, count = 0, x, y;
cin >> c >> distance;
distance *= distance;
for (int i = 0; i < c; i++) {
cin >> x >> y;
x *= x;
y *= y;
if (distance <= (x + y)) {
count++;
}
}
cout << count;
} | #include <iostream>
#include <string>
using namespace std;
int main() {
double c, distance, count = 0, x, y;
cin >> c >> distance;
distance *= distance;
for (int i = 0; i < c; i++) {
cin >> x >> y;
x *= x;
y *= y;
if (distance >= (x + y)) {
count++;
}
}
cout << count;
} | [
"variable_declaration.type.primitive.change",
"misc.opposites",
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,104 | 296,105 | u486604023 | cpp |
p02595 | #include <iostream>
#include <string>
using namespace std;
int main() {
int c, distance, count = 0, x, y;
cin >> c >> distance;
distance *= distance;
for (int i = 0; i < c; i++) {
cin >> x >> y;
x *= x;
y *= y;
if (distance >= (x + y)) {
count++;
}
}
cout << count;
} | #include <iostream>
#include <string>
using namespace std;
int main() {
double c, distance, count = 0, x, y;
cin >> c >> distance;
distance *= distance;
for (int i = 0; i < c; i++) {
cin >> x >> y;
x *= x;
y *= y;
if (distance >= (x + y)) {
count++;
}
}
cout << count;
} | [
"variable_declaration.type.primitive.change"
] | 296,106 | 296,105 | u486604023 | cpp |
p02595 | #include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
using namespace std;
typedef long long ll;
typedef long double ld;
const double E = 1e-7;
const ll INF = 1e17;
#define forn(i, s, f) for (int i = s; i < f; ++i)
#define ft first
#define sec second
#define fora(i, n) for (auto i ... | #include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
using namespace std;
typedef long long ll;
typedef long double ld;
const double E = 1e-7;
const ll INF = 1e17;
#define forn(i, s, f) for (int i = s; i < f; ++i)
#define ft first
#define sec second
#define fora(i, n) for (auto i ... | [
"variable_declaration.type.change"
] | 296,107 | 296,108 | u363187964 | cpp |
p02595 | #include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
using namespace std;
typedef long long ll;
typedef long double ld;
const double E = 1e-7;
const ll INF = 1e17;
#define forn(i, s, f) for (int i = s; i < f; ++i)
#define ft first
#define sec second
#define fora(i, n) for (auto i ... | #include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
using namespace std;
typedef long long ll;
typedef long double ld;
const double E = 1e-7;
const ll INF = 1e17;
#define forn(i, s, f) for (int i = s; i < f; ++i)
#define ft first
#define sec second
#define fora(i, n) for (auto i ... | [
"variable_declaration.type.change",
"identifier.change",
"control_flow.branch.if.condition.change"
] | 296,109 | 296,108 | u363187964 | cpp |
p02595 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int n, d, cnt = 0;
cin >> n >> d;
d *= d;
vector<int> x(n);
vector<int> y(n);
for (int i = 0; i < n; i++) {
cin >> x.at(i);
cin >> y.at(i);
}
for (int i = 0; i < n; i++) {
if (x.at(i) * x.at(i) + y.at(i) * y.at(i) <= d)
... | #include <iostream>
#include <vector>
using namespace std;
int main() {
long long n, d, cnt = 0;
cin >> n >> d;
d *= d;
vector<long long> x(n);
vector<long long> y(n);
for (int i = 0; i < n; i++) {
cin >> x.at(i);
cin >> y.at(i);
}
for (int i = 0; i < n; i++) {
if (x.at(i) * x.at(i) + y.at(i... | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change"
] | 296,110 | 296,111 | u343242669 | cpp |
p02595 | #include <iostream>
#include <vector>
using namespace std;
int main() {
int n, d;
int counter = 0;
cin >> n >> d;
long long d2 = d * d;
for (int i = 0; i < n; i++) {
int tmpx, tmpy;
cin >> tmpx >> tmpy;
long long tmpd = tmpx * tmpx + tmpy * tmpy;
if (d2 >= tmpd) {
counter++;
}
}
... | #include <iostream>
#include <vector>
using namespace std;
int main() {
long long n, d;
long long counter = 0;
cin >> n >> d;
long long d2 = d * d;
for (int i = 0; i < n; i++) {
long long tmpx, tmpy;
cin >> tmpx >> tmpy;
long long tmpd = tmpx * tmpx + tmpy * tmpy;
if (d2 >= tmpd) {
// co... | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change"
] | 296,112 | 296,113 | u633620412 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int n, d;
cin >> n >> d;
long long x[n], y[n];
for (int i = 0; i < n; i++) {
cin >> x[i] >> y[i];
}
double ans;
int cnt = 0;
for (int i = 0; i < n; i++) {
ans = sqrt(x[i] * x[i] + y[i] * y[i]);
if (ans < d)
cnt++;
}
cout <... | #include <bits/stdc++.h>
using namespace std;
int main() {
int n, d;
cin >> n >> d;
long long x[n], y[n];
for (int i = 0; i < n; i++) {
cin >> x[i] >> y[i];
}
double ans;
int cnt = 0;
for (int i = 0; i < n; i++) {
ans = sqrt(x[i] * x[i] + y[i] * y[i]);
if (ans <= d)
cnt++;
}
cout ... | [
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,116 | 296,117 | u864785784 | cpp |
p02595 | #include <iostream>
#include <string>
int main() {
// input
int N, D;
std::cin >> N >> D;
int X[N];
int Y[N];
int dSquare = D * D;
int result = 0;
for (int i = 0; i < N; i++) {
std::cin >> X[i] >> Y[i];
if (X[i] * X[i] + Y[i] * Y[i] <= dSquare) {
result++;
}
}
std::cout << resu... | #include <iostream>
#include <string>
int main() {
// input
long N, D;
std::cin >> N >> D;
long X[N];
long Y[N];
long dSquare = D * D;
long result = 0;
for (int i = 0; i < N; i++) {
std::cin >> X[i] >> Y[i];
if (X[i] * X[i] + Y[i] * Y[i] <= dSquare) {
result++;
}
}
std::cout <<... | [
"variable_declaration.type.primitive.change"
] | 296,118 | 296,119 | u047573796 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long ll;
#define all(x) x.begin(), x.end()
signed main() {
int n, d;
cin >> n >> d;
int ans = 0;
rep(i, n) {
int x, y;
cin >> x >> y;
double far;
far = sqrt((x * x) + (y * y));
if... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
typedef long long ll;
#define all(x) x.begin(), x.end()
signed main() {
ll n, d;
cin >> n >> d;
ll ans = 0;
rep(i, n) {
ll x, y;
cin >> x >> y;
double long far;
far = sqrt((x * x) + (y * y));
... | [
"variable_declaration.type.change"
] | 296,124 | 296,125 | u296989351 | cpp |
p02595 | #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>;
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) ... | #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>;
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return true;
}
return false;
}
template <class T> inline bool chmax(T &a, T b) {
if (a < b) ... | [
"variable_declaration.type.change"
] | 296,126 | 296,127 | u278557766 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define pii pair<int, int>
#define _FastIO \
ios_base::sync_with_stdio(0); \
cin.tie(0); ... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define pii pair<int, int>
#define _FastIO \
ios_base::sync_with_stdio(0); \
cin.tie(0); ... | [
"control_flow.loop.for.initializer.change",
"variable_declaration.type.change",
"misc.opposites",
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,128 | 296,129 | u958323734 | cpp |
p02595 | #include "bits/stdc++.h"
using namespace std;
int main() {
int n, ans = 0, x, y, d, dd, dis;
cin >> n >> d;
dd = d * d;
for (int i = 0; i < n; i++) {
cin >> x >> y;
dis = x * x + y * y;
if (dis <= d) {
ans++;
}
}
cout << ans << endl;
return 0;
} | #include "bits/stdc++.h"
using namespace std;
int main() {
long long n, ans = 0, x, y, d, dd, dis;
cin >> n >> d;
dd = d * d;
for (int i = 0; i < n; i++) {
cin >> x >> y;
dis = x * x + y * y;
if (dis <= dd) {
ans++;
}
}
cout << ans << endl;
return 0;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change",
"identifier.change",
"control_flow.branch.if.condition.change"
] | 296,130 | 296,131 | u878173555 | cpp |
p02595 | #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, d;
cin >> n >> d;
vector<int> x(n), y(n);
rep(i, n) cin >> x[i] >> y[i];
int cnt = 0;
rep(i, n) {
if (x[i] * x[i] + y[i] * y[i] <= d * d) {
... | #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() {
ll n, d;
cin >> n >> d;
vector<ll> x(n), y(n);
rep(i, n) cin >> x[i] >> y[i];
int cnt = 0;
rep(i, n) {
if (x[i] * x[i] + y[i] * y[i] <= d * d) {
... | [
"variable_declaration.type.change"
] | 296,137 | 296,138 | u497925439 | cpp |
p02595 | #include <iostream>
using namespace std;
const int N = 2e5 + 10;
int main() {
int n, d;
cin >> n >> d;
int ans = 0;
for (int i = 1, x, y; i <= n; ++i) {
cin >> x >> y;
if (x * x + y * y <= d * d)
ans++;
}
cout << ans << '\n';
return 0;
} | #include <iostream>
#define int long long
using namespace std;
const int N = 2e5 + 10;
signed main() {
int n, d;
cin >> n >> d;
int ans = 0;
for (int i = 1, x, y; i <= n; ++i) {
cin >> x >> y;
if (x * x + y * y <= d * d)
ans++;
}
cout << ans << '\n';
return 0;
} | [
"variable_declaration.type.primitive.change"
] | 296,154 | 296,155 | u242774620 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int n;
long long int d;
cin >> n >> d;
int ans = 0;
int x, y;
for (int i = 0; i < n; i++) {
cin >> x >> y;
if (x * x + y * y <= d * d)
ans++;
}
cout << ans;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int n;
long long int d;
cin >> n >> d;
int ans = 0;
long long int x, y;
for (int i = 0; i < n; i++) {
cin >> x >> y;
if (x * x + y * y <= d * d)
ans++;
}
cout << ans;
} | [
"variable_declaration.type.widen.change"
] | 296,156 | 296,157 | u983681697 | cpp |
p02595 | #include <assert.h>
#include <iostream>
//#include<vector>
#include <math.h>
#define ios \
ios::sync_with_stdio(false); \
cin.tie(0); \... | #include <assert.h>
#include <iostream>
//#include<vector>
#include <math.h>
#define ios \
ios::sync_with_stdio(false); \
cin.tie(0); \... | [] | 296,158 | 296,159 | u902015134 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int N, D;
cin >> N >> D;
int a, b;
int ans = 0;
for (int i = 1; i <= N; i++) {
cin >> a >> b;
if (a * a + b * b <= D * D)
ans++;
}
cout << ans << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long N, D;
cin >> N >> D;
long long a, b;
long long ans = 0;
for (int i = 1; i <= N; i++) {
cin >> a >> b;
if (a * a + b * b <= D * D)
ans++;
}
cout << ans << endl;
return 0;
} | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change"
] | 296,162 | 296,163 | u488901309 | cpp |
p02595 | /*
* Name : chaitanya
*
* Institute : ANITS,Visakhapatnam
* "Don't regret anything you do, because in the end it makes you who you
* are."
*
*/
#include <algorithm>
#include <bitset>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>... | /*
* Name : chaitanya
*
* Institute : ANITS,Visakhapatnam
* "Don't regret anything you do, because in the end it makes you who you
* are."
*
*/
#include <algorithm>
#include <bitset>
#include <cfloat>
#include <climits>
#include <cmath>
#include <complex>... | [
"variable_declaration.type.change"
] | 296,164 | 296,165 | u022688266 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef uint64_t bu;
typedef vector<ll> vll;
typedef vector<int> vi;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef vector<pll> vpl;
typedef vector<string> vs;
typedef vector<char> vc;
#define vb vector<bool>
#define pub push_back
#def... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef uint64_t bu;
typedef vector<ll> vll;
typedef vector<int> vi;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef vector<pll> vpl;
typedef vector<string> vs;
typedef vector<char> vc;
#define vb vector<bool>
#define pub push_back
#def... | [
"identifier.change",
"call.function.change"
] | 296,172 | 296,173 | u329333736 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef uint64_t bu;
typedef vector<ll> vll;
typedef vector<int> vi;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef vector<pll> vpl;
typedef vector<string> vs;
typedef vector<char> vc;
#define vb vector<bool>
#define pub push_back
#def... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef uint64_t bu;
typedef vector<ll> vll;
typedef vector<int> vi;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef vector<pll> vpl;
typedef vector<string> vs;
typedef vector<char> vc;
#define vb vector<bool>
#define pub push_back
#def... | [
"identifier.change",
"call.function.change",
"expression.operation.binary.remove"
] | 296,174 | 296,173 | u329333736 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
int n, d, S = 0;
cin >> n >> d;
d *= d;
for (int i = 0; i < n; i++) {
ll a, b;
cin >> a >> b;
if (a * a + b * b <= d)
S++;
}
cout << S << endl;
} | #include <bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
int n, S = 0;
ll d;
cin >> n >> d;
d *= d;
for (int i = 0; i < n; i++) {
ll a, b;
cin >> a >> b;
if (a * a + b * b <= d)
S++;
}
cout << S << endl;
}
| [
"variable_declaration.remove",
"variable_declaration.add"
] | 296,178 | 296,179 | u882098164 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int n, cnt;
double k;
cnt = 0;
cin >> n >> k;
while (n--) {
int x, y;
cin >> x >> y;
double dis = sqrt(x * x + y * y);
if (dis <= k)
cnt++;
}
cout << cnt << endl;
} |
#include <bits/stdc++.h>
#define int long long
using namespace std;
signed main() {
int n, cnt;
double k;
cnt = 0;
cin >> n >> k;
while (n--) {
int x, y;
cin >> x >> y;
double dis = sqrt(x * x + y * y);
if (dis <= k)
cnt++;
}
cout << cnt << endl;
} | [
"variable_declaration.type.primitive.change"
] | 296,195 | 296,196 | u490601354 | cpp |
p02595 | #include <iostream>
int main() {
int N = 0, D = 0, X = 0, Y = 0;
std::cin >> N >> D;
int answer = 0;
for (int count = 0; count < N; count++) {
std::cin >> X >> Y;
if (((X * X) + (Y * Y) - (D * D)) > 0) {
continue;
}
++answer;
}
std::cout << answer << std::endl;
}
| #include <iostream>
int main() {
int N = 0;
long long D = 0, X = 0, Y = 0;
std::cin >> N >> D;
int answer = 0;
for (int count = 0; count < N; count++) {
std::cin >> X >> Y;
if (((X * X) + (Y * Y) - (D * D)) > 0) {
continue;
}
++answer;
}
std::cout << answer << std::endl;
}
| [
"variable_declaration.type.widen.change"
] | 296,204 | 296,205 | u307317373 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int n, d, x, y, ctr = 0;
double max;
cin >> n >> d;
while (n--) {
cin >> x >> y;
max = sqrt(x * x + y * y);
if (max <= d)
ctr++;
}
cout << ctr << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long int n, d, x, y, ctr = 0;
double max;
cin >> n >> d;
while (n--) {
cin >> x >> y;
max = sqrt(x * x + y * y);
if (max <= d)
ctr++;
}
cout << ctr << endl;
}
| [
"variable_declaration.type.widen.change"
] | 296,206 | 296,207 | u998366407 | cpp |
p02595 | #include <bits/stdc++.h>
#define ll long long
using namespace std;
const int INF = 1e9 + 7;
bool isPerfectSquare(ll x) {
ll s = sqrt(x);
return (s * s == x);
}
int main() {
ios::sync_with_stdio(false);
int n, d;
cin >> n >> d;
int ans = 0;
for (int i = 0; i < n; ++i) {
ll x, y;
cin >> x >> y;
... | #include <bits/stdc++.h>
#define ll long long
using namespace std;
const int INF = 1e9 + 7;
bool isPerfectSquare(ll x) {
ll s = sqrt(x);
return (s * s == x);
}
int main() {
ios::sync_with_stdio(false);
int n, d;
cin >> n >> d;
int ans = 0;
for (int i = 0; i < n; ++i) {
ll x, y;
cin >> x >> y;
... | [
"control_flow.branch.if.condition.change",
"control_flow.loop.for.condition.change"
] | 296,208 | 296,209 | u584976442 | cpp |
p02595 | #include <bits/stdc++.h>
namespace ztd {
using namespace std;
#define reg register
#define ms(a) memset(a, 0, sizeof(a))
#define count(x) __builtin_popcountll(x)
#define smallest_one(x) __builtin_ffsll(x)
typedef long long ll;
typedef unsigned long long ull;
typedef unsigned int uint;
typedef double db;
// basic I/O
te... | #include <bits/stdc++.h>
namespace ztd {
using namespace std;
#define reg register
#define ms(a) memset(a, 0, sizeof(a))
#define count(x) __builtin_popcountll(x)
#define smallest_one(x) __builtin_ffsll(x)
typedef long long ll;
typedef unsigned long long ull;
typedef unsigned int uint;
typedef double db;
// basic I/O
te... | [
"misc.opposites",
"expression.operator.compare.change",
"control_flow.branch.if.condition.change"
] | 296,213 | 296,214 | u027550957 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int N, D;
cin >> N >> D;
int X, Y, i, l;
int n = 0;
for (i = 0; i < N; i++) {
cin >> X >> Y;
l = sqrt(pow(X, 2) + pow(Y, 2));
if (l <= D)
n += 0;
}
cout << n << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int N, D;
cin >> N >> D;
int X, Y, i;
double l;
int n = 0;
for (i = 0; i < N; i++) {
cin >> X >> Y;
l = sqrt(pow(X, 2) + pow(Y, 2));
if (l <= D)
n++;
}
cout << n << endl;
return 0;
} | [
"variable_declaration.type.change"
] | 296,215 | 296,216 | u917685349 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
int N, D;
cin >> N >> D;
int X, Y;
int ans = 0;
for (int i = 0; i < N; i++) {
cin >> X >> Y;
if (sqrt(X * X + Y * Y) <= D) {
ans++;
}
}
cout << ans << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int N, D;
cin >> N >> D;
long X, Y;
int ans = 0;
for (int i = 0; i < N; i++) {
cin >> X >> Y;
if (sqrt(X * X + Y * Y) <= D) {
ans++;
}
}
cout << ans << endl;
return 0;
}
| [
"variable_declaration.type.primitive.change"
] | 296,217 | 296,218 | u923051067 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
int n, d;
cin >> n >> d;
int cnt = 0;
int rez = 0;
while (n--) {
int a, b;
cin >> a >> b;
rez = pow(a, 2) + pow(b, 2);
if (sqrt(rez) <= d) {
cnt++;
}
}
cout << cnt;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
int n, d;
cin >> n >> d;
int cnt = 0;
long long rez = 0;
while (n--) {
int a, b;
cin >> a >> b;
rez = pow(a, 2) + pow(b, 2);
if (sqrt(rez) <= d) {
cnt++;
}
}
cout << cnt;
}
| [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change"
] | 296,219 | 296,220 | u975685934 | cpp |
p02595 | #include <bits/stdc++.h>
using namespace std;
#define fi first
#define se second
#define all(a) a.begin(), a.end()
#define pb push_back
#define mp make_pair
typedef long long ll;
typedef pair<ll, ll> P;
typedef pair<ll, int> pli;
typedef pair<int, int> pii;
#define rep(i, a, b) for (ll i = a; i < b; i++)
#define qrep(q... | #include <bits/stdc++.h>
using namespace std;
#define fi first
#define se second
#define all(a) a.begin(), a.end()
#define pb push_back
#define mp make_pair
typedef long long ll;
typedef pair<ll, ll> P;
typedef pair<ll, int> pli;
typedef pair<int, int> pii;
#define rep(i, a, b) for (ll i = a; i < b; i++)
#define qrep(q... | [
"variable_declaration.type.change"
] | 296,228 | 296,229 | u363005934 | cpp |
p02595 | #include <cmath>
#include <iostream>
using namespace std;
int main() {
int64_t nof, d;
cin >> nof >> d;
int64_t tot = 0;
int64_t p1, p2;
for (size_t i{0}; i != nof; ++i) {
cin >> p1 >> p2;
if (sqrt(p1 * p1 + p2 * p2) <= d)
++tot;
}
} | #include <cmath>
#include <iostream>
using namespace std;
int main() {
int64_t nof, d;
cin >> nof >> d;
int64_t tot = 0;
int64_t p1, p2;
for (size_t i{0}; i != nof; ++i) {
cin >> p1 >> p2;
if (sqrt(p1 * p1 + p2 * p2) <= d)
++tot;
}
cout << tot;
}
| [] | 296,230 | 296,231 | u708137940 | cpp |
p02595 | //
// main.cpp
// B
//
// Created by Yoshinao Itakura on 2020/08/02.
// Copyright © 2020 Yoshinao Itakura. All rights reserved.
//
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#include <vector>
using ... | //
// main.cpp
// B
//
// Created by Yoshinao Itakura on 2020/08/02.
// Copyright © 2020 Yoshinao Itakura. All rights reserved.
//
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#include <vector>
using ... | [
"variable_declaration.type.primitive.change",
"variable_declaration.type.widen.change"
] | 296,234 | 296,235 | u174031584 | cpp |
p02596 | #include <bits/stdc++.h>
#define rep(i, ss, ee) for (int i = ss; i < ee; ++i)
using namespace std;
int k;
void input() { cin >> k; }
void exit_end(int ans) {
cout << ans << endl;
exit(0);
}
void solve() {
vector<int> v(k + 1, -1);
if (k % 2 == 0)
exit_end(-1);
v[1] = 7 % k;
rep(i, 2, k) v[i] = (v[i ... | #include <bits/stdc++.h>
#define rep(i, ss, ee) for (int i = ss; i < ee; ++i)
using namespace std;
int k;
void input() { cin >> k; }
void exit_end(int ans) {
cout << ans << endl;
exit(0);
}
void solve() {
vector<int> v(k + 1, -1);
if (k % 2 == 0)
exit_end(-1);
v[1] = 7 % k;
rep(i, 2, k + 1) v[i] = (... | [
"assignment.change"
] | 296,243 | 296,244 | u748712781 | cpp |
p02596 | #include <iostream>
int main(void) {
int k;
std::cin >> k;
int cur = 7;
int cnt = 1;
for (int i = 0; i <= k; i++) {
if (cur == 0) {
std::cout << cnt << std::endl;
return 0;
} else {
cnt++;
cur = cur * 10 + 7;
cur %= k;
}
}
std::cout << -1 << std::endl;
return 0... | #include <iostream>
int main(void) {
int k;
std::cin >> k;
int cur = 7 % k;
int cnt = 1;
for (int i = 0; i <= k; i++) {
if (cur == 0) {
std::cout << cnt << std::endl;
return 0;
} else {
cnt++;
cur = cur * 10 + 7;
cur %= k;
}
}
std::cout << -1 << std::endl;
retu... | [
"assignment.change"
] | 296,248 | 296,249 | u275256557 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define print cout <<
#define printl(s) cout << s << endl;
#define rep(i, n) for (int i = 0; i < (n); ++i)
using ll = long long;
const ll modseed = pow(10, 9) + 7;
template <typename T> vector<T> getValues(int num) {
vector<T> values(num);
for (int i = 0; i < num; i+... | #include <bits/stdc++.h>
using namespace std;
#define print cout <<
#define printl(s) cout << s << endl;
#define rep(i, n) for (int i = 0; i < (n); ++i)
using ll = long long;
const ll modseed = pow(10, 9) + 7;
template <typename T> vector<T> getValues(int num) {
vector<T> values(num);
for (int i = 0; i < num; i+... | [
"expression.operator.compare.change",
"control_flow.loop.for.condition.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 296,252 | 296,253 | u188687538 | cpp |
p02596 | #include <iostream>
#include <math.h>
#include <set>
using namespace std;
int main() {
int n;
cin >> n;
int ans = 1;
long long m = 7;
while (ans <= n) {
m = (10 * m + 7) % n;
// cout<<m<<endl;
if (m % n == 0)
break;
ans++;
}
if (ans <= n)
cout << ans + 1;
else
cout <... | #include <iostream>
#include <math.h>
#include <set>
using namespace std;
int main() {
int n;
cin >> n;
int ans = 1;
long long m = 0;
while (ans <= n) {
m = (10 * m + 7) % n;
// cout<<m<<endl;
if (m % n == 0)
break;
ans++;
}
if (ans <= n)
cout << ans;
else
cout << -1... | [
"literal.number.change",
"variable_declaration.value.change",
"expression.operation.binary.remove"
] | 296,262 | 296,263 | u089230684 | cpp |
p02596 | #include <bits/stdc++.h>
using ll = long long;
using namespace std;
ll modpow(ll n, ll x, ll MOD) {
ll ret = 1;
while (x) {
if (x & 1) {
(ret *= n) %= MOD;
}
x >>= 1;
(n *= n) %= MOD;
}
return ret;
}
int main() {
int k;
cin >> k;
if (k % 7 == 0) {
for (int i = 1; i < k; ++i) {
... | #include <bits/stdc++.h>
using ll = long long;
using namespace std;
ll modpow(ll n, ll x, ll MOD) {
ll ret = 1;
while (x) {
if (x & 1) {
(ret *= n) %= MOD;
}
x >>= 1;
(n *= n) %= MOD;
}
return ret;
}
int main() {
int k;
cin >> k;
if (k % 7 == 0) {
for (int i = 1; i <= k; ++i) {
... | [
"expression.operator.compare.change",
"control_flow.branch.if.condition.change",
"literal.number.change",
"io.output.change"
] | 296,264 | 296,265 | u007332755 | cpp |
p02596 | #include <iostream>
using namespace std;
int main(void) {
long long int n, k;
cin >> k;
for (int i = 1; i < 150000000; i++) {
n = 10 * n + 7;
n = n % k;
if (n == 0) {
cout << i << endl;
return 0;
}
}
cout << "-1" << endl;
} | #include <iostream>
using namespace std;
int main(void) {
long long int n, k;
cin >> k;
n = 0;
for (int i = 1; i < 1000000; i++) {
n = 10 * n + 7;
n = n % k;
if (n == 0) {
cout << i << endl;
return 0;
}
}
cout << "-1" << endl;
} | [
"assignment.add",
"literal.number.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change"
] | 296,270 | 296,271 | u491376630 | cpp |
p02596 | #include <iostream>
using namespace std;
int main(void) {
long long int n, k;
cin >> k;
for (int i = 1; i < 150000000; i++) {
n = 10 * n + 7;
n = n % k;
if (n == 0) {
cout << i << endl;
return 0;
}
}
cout << "-1" << endl;
} | #include <iostream>
using namespace std;
int main(void) {
long long int n, k;
cin >> k;
n = 0;
for (int i = 1; i < 150000000; i++) {
n = 10 * n + 7;
n = n % k;
if (n == 0) {
cout << i << endl;
return 0;
}
}
cout << "-1" << endl;
} | [
"assignment.add"
] | 296,270 | 296,272 | u491376630 | cpp |
p02596 | #include <bits/stdc++.h>
#define ll long long
#define rep(i, n) for (ll i = 0; i < n; i++)
#define repr(i, a, b) for (ll i = a; i < b; i++)
#define all(a) a.begin(), a.end()
#define w(tc) \
ll tc; ... | #include <bits/stdc++.h>
#define ll long long
#define rep(i, n) for (ll i = 0; i < n; i++)
#define repr(i, a, b) for (ll i = a; i < b; i++)
#define all(a) a.begin(), a.end()
#define w(tc) \
ll tc; ... | [
"literal.number.change",
"variable_declaration.value.change",
"assignment.value.change",
"control_flow.loop.for.initializer.change",
"expression.off_by_one"
] | 296,273 | 296,274 | u450359369 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#include <iomanip>
#include <math.h>
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return 1;
}
return 0;
}
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return 1;
}
return 0;
}
const int mod = 1000... | #include <bits/stdc++.h>
using namespace std;
#include <iomanip>
#include <math.h>
template <class T> inline bool chmax(T &a, T b) {
if (a < b) {
a = b;
return 1;
}
return 0;
}
template <class T> inline bool chmin(T &a, T b) {
if (a > b) {
a = b;
return 1;
}
return 0;
}
const int mod = 1000... | [
"expression.operation.binary.remove"
] | 296,275 | 296,276 | u209457657 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; i++)
typedef long long ll;
/*
ll n , m ;
cin >> n >> m ;
ll a , b , c ;
cin >> a >> b >> c ;
vector<ll> A(n) ;
cout << "Yes" << endl ;
cout << "No" << endl ;
*/
int main() {
ll n;
cin >> n;
ll ans = 7 % n;
fo... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < n; i++)
typedef long long ll;
/*
ll n , m ;
cin >> n >> m ;
ll a , b , c ;
cin >> a >> b >> c ;
vector<ll> A(n) ;
cout << "Yes" << endl ;
cout << "No" << endl ;
*/
int main() {
ll n;
cin >> n;
ll ans = 7 % n;
fo... | [
"assignment.value.change"
] | 296,277 | 296,278 | u854161810 | cpp |
p02596 |
// Problem :
// C - Repsept
// Editorial
//
// Contest : AtCoder - AtCoder Beginner Contest 174
// URL : https://atcoder.jp/contests/abc174/tasks/abc174_c
// Memory Limit : 1024 MB
// Time Limit : 2000 ms
// Powered by CP Editor (https://github.com/cpeditor/cpeditor)
#include <bits/stdc++.h>
#pragma GCC target(... |
// Problem :
// C - Repsept
// Editorial
//
// Contest : AtCoder - AtCoder Beginner Contest 174
// URL : https://atcoder.jp/contests/abc174/tasks/abc174_c
// Memory Limit : 1024 MB
// Time Limit : 2000 ms
// Powered by CP Editor (https://github.com/cpeditor/cpeditor)
#include <bits/stdc++.h>
#pragma GCC target(... | [
"literal.number.change",
"variable_declaration.value.change",
"assignment.value.change",
"expression.operation.binary.change"
] | 296,279 | 296,280 | u684833327 | cpp |
p02596 |
// Problem : C - Repsept
// Contest : AtCoder - AtCoder Beginner Contest 174
// URL : https://atcoder.jp/contests/abc174/tasks/abc174_c
// Memory Limit : 1024 MB
// Time Limit : 2000 ms
// Powered by CP Editor (https://github.com/cpeditor/cpeditor)
#include <bits/stdc++.h>
#pragma GCC target("avx,avx2,fma")
//#pragma... |
// Problem : C - Repsept
// Contest : AtCoder - AtCoder Beginner Contest 174
// URL : https://atcoder.jp/contests/abc174/tasks/abc174_c
// Memory Limit : 1024 MB
// Time Limit : 2000 ms
// Powered by CP Editor (https://github.com/cpeditor/cpeditor)
#include <bits/stdc++.h>
#pragma GCC target("avx,avx2,fma")
//#pragma... | [
"literal.number.change",
"variable_declaration.value.change"
] | 296,281 | 296,282 | u684833327 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
int n, m;
int a[1000], b[1000];
int main() {
int k;
cin >> k;
if (k == 1) {
cout << 7 << endl;
return 0;
}
if (k % 7 == 0) {
k = k / 7;
}
if (__gcd(10, k) != 1) {
cout << -1 << endl;
return 0;
}
int c = 1... | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
int n, m;
int a[1000], b[1000];
int main() {
int k;
cin >> k;
if (k == 1) {
cout << 1 << endl;
return 0;
}
if (k % 7 == 0) {
k = k / 7;
}
if (__gcd(10, k) != 1) {
cout << -1 << endl;
return 0;
}
int c = 1... | [
"literal.number.change",
"io.output.change"
] | 296,285 | 296,286 | u495721259 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
#define all(n) begin(n), end(n)
using ll = long long;
using P = pair<int, int>;
int main() {
ll k;
cin >> k;
vector<int> num(k + 1);
num[0] = 7 % k;
if (k == 7) {
cout << 1 << endl;
return 0;
}
rep(i, k)... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (n); i++)
#define all(n) begin(n), end(n)
using ll = long long;
using P = pair<int, int>;
int main() {
ll k;
cin >> k;
vector<int> num(k + 1);
num[0] = 7 % k;
if (num[0] == 0) {
cout << 1 << endl;
return 0;
}
rep(... | [
"control_flow.branch.if.condition.change",
"literal.number.change"
] | 296,295 | 296,296 | u074488832 | cpp |
p02596 | #include <bits/stdc++.h>
typedef long long ll;
#define pb push_back
#define mod 1000000007ll
const ll maxn = 9e18;
using namespace std;
void solve() {
int k;
cin >> k;
int num = 7 % 9, i = 0;
map<int, int> m;
while (1) {
m[num]++;
if (m[num] > 1) {
cout << -1 << endl;
return;
}
if... | #include <bits/stdc++.h>
typedef long long ll;
#define pb push_back
#define mod 1000000007ll
const ll maxn = 9e18;
using namespace std;
void solve() {
int k;
cin >> k;
ll num = 7 % k, i = 0;
map<int, int> m;
while (1) {
m[num]++;
if (m[num] > 1) {
cout << -1 << endl;
return;
}
if ... | [
"variable_declaration.type.change",
"identifier.replace.add",
"literal.replace.remove",
"expression.operation.binary.change"
] | 296,299 | 296,300 | u552056877 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int k;
cin >> k;
map<int, int> mp;
int num = 7;
int ans = 1;
while (1) {
mp[num]++;
if (num == 0) {
cout << ans << endl;
return 0;
}
if (mp[num] > 1) {
cout << -1 << endl;
return 0;
}
num = (num * ... | #include <bits/stdc++.h>
using namespace std;
int main() {
int k;
cin >> k;
map<int, int> mp;
int num = 7 % k;
int ans = 1;
while (1) {
mp[num]++;
if (num == 0) {
cout << ans << endl;
return 0;
}
if (mp[num] > 1) {
cout << -1 << endl;
return 0;
}
num = (nu... | [
"assignment.change"
] | 296,301 | 296,302 | u685233906 | cpp |
p02596 | #include "bits/stdc++.h"
#define fastio ios_base::sync_with_stdio(false)
#define ll long long int
#define ld long double
#define ict \
int t; \
cin >> t
#define lct ... | #include "bits/stdc++.h"
#define fastio ios_base::sync_with_stdio(false)
#define ll long long int
#define ld long double
#define ict \
int t; \
cin >> t
#define lct ... | [
"control_flow.branch.if.condition.change"
] | 296,323 | 296,324 | u327771863 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> a(1000001);
int k;
cin >> k;
a[1] = 7 % k;
for (int i = 2; i < k; i++) {
a[i] = (a[i - 1] * 10 + 7) % k;
}
for (int i = 1; i < k; i++) {
if (a[i] == 0) {
cout << i << endl;
return 0;
}
}
cout << -1 << endl;... | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> a(1000001);
int k;
cin >> k;
a[1] = 7 % k;
for (int i = 2; i <= 1000000; i++) {
a[i] = (a[i - 1] * 10 + 7) % k;
}
for (int i = 1; i <= 1000000; i++) {
if (a[i] == 0) {
cout << i << endl;
return 0;
}
}
cout ... | [
"control_flow.loop.for.condition.change"
] | 296,325 | 296,326 | u818755983 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll k, num = 0, cnt = 0;
int main() {
while (cnt <= k) {
num = (num * 10 + 7) % k;
cnt++;
if (!num) {
cout << cnt;
return 0;
}
}
cout << "-1";
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll k, num = 0, cnt = 0;
int main() {
cin >> k;
while (cnt <= k) {
num = (num * 10 + 7) % k;
cnt++;
if (!num) {
cout << cnt;
return 0;
}
}
cout << "-1";
return 0;
}
| [] | 296,344 | 296,345 | u409878193 | cpp |
p02596 |
// .----------------. .----------------. .----------------.
// .----------------. .----------------. .----------------.
// .----------------. .----------------. .----------------.
// | .--------------. || .--------------. || .--------------. ||
// .--------------. || .--------------. || .--------------. ... |
// .----------------. .----------------. .----------------.
// .----------------. .----------------. .----------------.
// .----------------. .----------------. .----------------.
// | .--------------. || .--------------. || .--------------. ||
// .--------------. || .--------------. || .--------------. ... | [
"literal.number.change",
"variable_declaration.value.change",
"control_flow.loop.condition.change"
] | 296,346 | 296,347 | u371537444 | cpp |
p02596 | #include <iostream>
using namespace std;
int main() {
long long i = 1, k, c = 0;
cin >> k;
while (i <= k) {
c = (c * 10) + 7;
if (c % k == 0) {
cout << i;
return 0;
}
i++;
}
cout << "-1";
} | #include <iostream>
using namespace std;
int main() {
long long i = 1, k, c = 0;
cin >> k;
while (i <= k) {
c = (c * 10) + 7;
c = c % k;
if (c == 0) {
cout << i;
return 0;
}
i++;
}
cout << "-1";
} | [
"control_flow.branch.if.add"
] | 296,353 | 296,354 | u077637142 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int k;
cin >> k;
if (k % 2 == 0)
cout << "-1";
else if (k % 5 == 0)
cout << "-1";
else {
int nana = 7;
int ans = 1;
for (int i = 0; i <= k; i++) {
if (nana % k == 0) {
cout << ans;
break;
} else if (i ==... | #include <bits/stdc++.h>
using namespace std;
int main() {
int k;
cin >> k;
if (k % 2 == 0)
cout << "-1";
else if (k % 5 == 0)
cout << "-1";
else {
int nana = 7;
int ans = 1;
for (int i = 0; i <= k; i++) {
if (nana % k == 0) {
cout << ans;
break;
} else if (i ==... | [
"assignment.change"
] | 296,358 | 296,359 | u799331745 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int k, x = 0;
scanf("%d", &k);
for (int i = 1; i <= k; i++) {
x = (x * 10 + 1) % k;
if (!x) {
printf("%d", i);
return 0;
}
}
printf("-1");
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int k, x = 0;
scanf("%d", &k);
for (int i = 1; i <= k; i++) {
x = (x * 10 + 7) % k;
if (!x) {
printf("%d", i);
return 0;
}
}
printf("-1");
} | [
"literal.number.change",
"assignment.value.change",
"expression.operation.binary.change"
] | 296,370 | 296,371 | u514853560 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using P = pair<int, int>;
using vint = vector<int>;
using vvint = vector<vint>;
using vll = vector<ll>;
using vvll = vector<vll>;
using vchar = vector<char>;
using vvchar = vector<vchar>;
using vp = vector<P>;
using vpp = vector<pair<P, P>>;
using vvp ... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using P = pair<int, int>;
using vint = vector<int>;
using vvint = vector<vint>;
using vll = vector<ll>;
using vvll = vector<vll>;
using vchar = vector<char>;
using vvchar = vector<vchar>;
using vp = vector<P>;
using vpp = vector<pair<P, P>>;
using vvp ... | [
"control_flow.branch.if.condition.change"
] | 296,374 | 296,375 | u395620499 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int K;
cin >> K;
if (K % 10 == 0 || K % 10 == 2 || K % 10 == 4 || K % 10 == 5 || K % 10 == 6 ||
K % 10 == 8) {
cout << -1 << endl;
return 0;
}
if (K == 1) {
cout << 1 << endl;
return 0;
}
int N = K % 7;
int M = N;
int... | #include <bits/stdc++.h>
using namespace std;
int main() {
int K;
cin >> K;
if (K % 10 == 0 || K % 10 == 2 || K % 10 == 4 || K % 10 == 5 || K % 10 == 6 ||
K % 10 == 8) {
cout << -1 << endl;
return 0;
}
if (K == 1) {
cout << 1 << endl;
return 0;
}
int N = 7 % K;
int M = N;
int... | [
"expression.operation.binary.remove"
] | 296,380 | 296,381 | u710877960 | cpp |
p02596 | #include <algorithm>
#include <cmath>
#include <iostream>
#include <vector>
using namespace std;
using ll = long long;
int main() {
ll k = 0;
ll ans = -1;
cin >> k;
vector<ll> vec;
vec.emplace_back(7 % k);
for (ll i = 1; i < k; i++) {
vec.emplace_back((vec[i - 1] * 10 + 7) % k);
}
for (ll i ... | #include <algorithm>
#include <cmath>
#include <iostream>
#include <vector>
using namespace std;
using ll = long long;
int main() {
ll k = 0;
ll ans = -1;
cin >> k;
vector<ll> vec;
vec.emplace_back(7 % k);
for (ll i = 1; i < k; i++) {
vec.emplace_back((vec[i - 1] * 10 + 7) % k);
}
for (ll i ... | [
"assignment.value.change"
] | 296,388 | 296,389 | u182520620 | cpp |
p02596 | // ABC174C
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define rep(i, c) for (long long i = 0; i < (long long)c; i++)
const ll INF = 1000000000000001;
int main() {
int k;
cin >> k;
int n = 7;
int ans = -1;
for (int i = 1; i <= k; i++) {
if ((n % k) == 0) {
ans = i;
brea... | // ABC174C
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define rep(i, c) for (long long i = 0; i < (long long)c; i++)
const ll INF = 1000000000000001;
int main() {
int k;
cin >> k;
int n = 7;
int ans = -1;
for (int i = 1; i <= k; i++) {
if ((n % k) == 0) {
ans = i;
brea... | [
"assignment.value.change",
"identifier.replace.add",
"literal.replace.remove",
"expression.operation.binary.change"
] | 296,390 | 296,391 | u482982799 | cpp |
p02596 | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
using ll = long long;
int main() {
int k;
cin >> k;
ll t = 7, s = 0;
for (int i = 1; i < k; i++) {
s += t;
s %= k;
t *= 10;
t %= k;
if (s ... | #include <algorithm>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <string>
#include <vector>
using namespace std;
using ll = long long;
int main() {
int k;
cin >> k;
ll t = 7, s = 0;
for (int i = 1; i < k * 10; i++) {
s += t;
s %= k;
t *= 10;
t %= k;
i... | [
"control_flow.loop.for.condition.change"
] | 296,402 | 296,403 | u215860196 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define int long long int
#define endl '\n'
int32_t main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
int n;
cin >> n;
int num = 7;
int cnt = 1;
if (n % 2 == 0)
cout << "-1" << endl;
else {
int ans = -1;
for (int i = 2; ... | #include <bits/stdc++.h>
using namespace std;
#define int long long int
#define endl '\n'
int32_t main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
int n;
cin >> n;
int num = 0;
int cnt = 0;
if (n % 2 == 0)
cout << "-1" << endl;
else {
int ans = -1;
for (int i = 1; ... | [
"literal.number.change",
"variable_declaration.value.change",
"control_flow.loop.for.initializer.change",
"expression.off_by_one"
] | 296,404 | 296,405 | u975895313 | cpp |
p02596 | #include <bits/stdc++.h>
#define MAX 10000000
using namespace std;
using ll = long long;
using P = pair<int, int>;
int main() {
int k = 0;
cin >> k;
ll seed = k % 7;
int i = 1;
set<int> s;
while (s.count(seed) == 0) {
if (seed == 0) {
cout << i << endl;
return 0;
}
s.insert(seed);... | #include <bits/stdc++.h>
#define MAX 10000000
using namespace std;
using ll = long long;
using P = pair<int, int>;
int main() {
int k = 0;
cin >> k;
ll seed = 7 % k;
int i = 1;
set<int> s;
while (s.count(seed) == 0) {
if (seed == 0) {
cout << i << endl;
return 0;
}
s.insert(seed);... | [
"expression.operation.binary.remove"
] | 296,410 | 296,411 | u478254786 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
bool checkValue(long long v) {
while (v > 0) {
if ((v % 7 != 0) || (v % 10 == 0))
return false;
v /= 10;
}
return true;
}
int main() {
long long x;
cin >> x;
unsigned long long value = 7;
vector<long long> result;
long long cnt = 0;
while (va... | #include <bits/stdc++.h>
using namespace std;
bool checkValue(long long v) {
while (v > 0) {
if ((v % 7 != 0) || (v % 10 == 0))
return false;
v /= 10;
}
return true;
}
int main() {
long long x;
cin >> x;
unsigned long long value = 7;
vector<long long> result;
long long cnt = 0;
while (va... | [
"literal.number.change",
"control_flow.branch.if.condition.change"
] | 296,424 | 296,425 | u708721324 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define mp make_pair
#define pb push_back
int main() {
ll k, n;
cin >> k;
n = k % 7;
for (ll i = 1; i <= 10000000; i++) {
if (n == 0) {
cout << i;
return 0;
}
n = (n * 10LL + 7LL) % k;
}
cout << -1;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define mp make_pair
#define pb push_back
int main() {
ll k, n;
cin >> k;
n = 7 % k;
for (ll i = 1; i <= 10000000; i++) {
if (n == 0) {
cout << i;
return 0;
}
n = (n * 10LL + 7LL) % k;
}
cout << -1;
return 0;
} | [
"expression.operation.binary.remove",
"assignment.change"
] | 296,439 | 296,440 | u267058418 | cpp |
p02596 | #include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rrep(i, n) for (int i = 1; i < (n + 1); ++i)
const double PI = 3.141592653589793238463;
using namespace std;
using ll = long long;
const ll INF = +10010010000;
typedef pair<int, int> P;
const int mod = 1e9 + 7;
stru... | #include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rrep(i, n) for (int i = 1; i < (n + 1); ++i)
const double PI = 3.141592653589793238463;
using namespace std;
using ll = long long;
const ll INF = +10010010000;
typedef pair<int, int> P;
const int mod = 1e9 + 7;
stru... | [
"assignment.change"
] | 296,446 | 296,447 | u412659798 | cpp |
p02596 | #include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rrep(i, n) for (int i = 1; i < (n + 1); ++i)
const double PI = 3.141592653589793238463;
using namespace std;
using ll = long long;
const ll INF = +10010010000;
typedef pair<int, int> P;
const int mod = 1e9 + 7;
stru... | #include <bits/stdc++.h>
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define rrep(i, n) for (int i = 1; i < (n + 1); ++i)
const double PI = 3.141592653589793238463;
using namespace std;
using ll = long long;
const ll INF = +10010010000;
typedef pair<int, int> P;
const int mod = 1e9 + 7;
stru... | [
"assignment.change"
] | 296,448 | 296,447 | u412659798 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
long long n, a, i;
cin >> n;
a = 7;
for (i = 1; i <= n; i++) {
if (a % n == 0) {
cout << i;
return 0;
}
a = a * 10 + 7;
}
cout << -1;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
long long n, a, i;
cin >> n;
a = 7;
for (i = 1; i <= n; i++) {
a = a % n;
if (a == 0) {
cout << i;
return 0;
}
a = a * 10 + 7;
}
cout << -1;
return 0;
} | [
"control_flow.branch.if.add"
] | 296,449 | 296,450 | u716358853 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using st = string;
using P = pair<int, int>;
using bl = bool;
using ch = char;
#define mrep(i, m, n) for (int i = m; i < (n); i++)
#define rep(i, n) mrep(i, 0, n)
#define chmax(x, y) \
{ x = ... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using st = string;
using P = pair<int, int>;
using bl = bool;
using ch = char;
#define mrep(i, m, n) for (int i = m; i < (n); i++)
#define rep(i, n) mrep(i, 0, n)
#define chmax(x, y) \
{ x = ... | [
"preprocessor.define.value.change",
"literal.float.change"
] | 296,451 | 296,452 | u074141555 | cpp |
p02596 | #include <algorithm>
#include <cmath>
#include <deque>
#include <iostream>
#include <iterator>
#include <list>
#include <map>
#include <memory>
#include <queue>
#include <set>
#include <stack>
#include <utility>
#include <vector>
#define rep0(i, n) for (i = 0; i < n; i++)
#define rep(s, i, n) for (i = s; i < n; i++)
us... | #include <algorithm>
#include <cmath>
#include <deque>
#include <iostream>
#include <iterator>
#include <list>
#include <map>
#include <memory>
#include <queue>
#include <set>
#include <stack>
#include <utility>
#include <vector>
#define rep0(i, n) for (i = 0; i < n; i++)
#define rep(s, i, n) for (i = s; i < n; i++)
us... | [
"expression.operation.binary.remove"
] | 296,453 | 296,454 | u365152996 | cpp |
p02596 | #include <algorithm>
#include <cmath>
#include <deque>
#include <iostream>
#include <iterator>
#include <list>
#include <map>
#include <memory>
#include <queue>
#include <set>
#include <stack>
#include <utility>
#include <vector>
#define rep0(i, n) for (i = 0; i < n; i++)
#define rep(s, i, n) for (i = s; i < n; i++)
us... | #include <algorithm>
#include <cmath>
#include <deque>
#include <iostream>
#include <iterator>
#include <list>
#include <map>
#include <memory>
#include <queue>
#include <set>
#include <stack>
#include <utility>
#include <vector>
#define rep0(i, n) for (i = 0; i < n; i++)
#define rep(s, i, n) for (i = s; i < n; i++)
us... | [
"assignment.change"
] | 296,455 | 296,454 | u365152996 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int k;
cin >> k;
if (k % 2 == 0 || k % 5 == 0) {
cout << -1 << '\n';
return 0;
}
long long n = 7, i;
for (i = 1; i <= k; ++i) {
if (n == 0)
break;
n = (n * 10 + 7) % k;
}
cout << i << '\n';
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int k;
cin >> k;
if (k % 2 == 0 || k % 5 == 0) {
cout << -1 << '\n';
return 0;
}
long long n = 7, i;
for (i = 1; i <= k; ++i) {
if (n % k == 0)
break;
n = (n * 10 + 7) % k;
}
cout << i << '\n';
return 0;
}
| [
"control_flow.branch.if.condition.change",
"control_flow.loop.for.condition.change"
] | 296,456 | 296,457 | u959524814 | cpp |
p02596 | #include <algorithm>
#include <cmath> //abs()かfabs()で少数絶対値
#include <cstdlib> //abs()で整数絶対値
#include <deque>
#include <functional> //sort第三引数greater<型名>()で降順
#include <iomanip> //cout<<setw(数字) で空白による桁揃え
#include <iostream> //cout<<right で右揃え
#include <map>
#include <queue>
#include <string>
#include <vector>
u... | #include <algorithm>
#include <cmath> //abs()かfabs()で少数絶対値
#include <cstdlib> //abs()で整数絶対値
#include <deque>
#include <functional> //sort第三引数greater<型名>()で降順
#include <iomanip> //cout<<setw(数字) で空白による桁揃え
#include <iostream> //cout<<right で右揃え
#include <map>
#include <queue>
#include <string>
#include <vector>
u... | [] | 296,461 | 296,462 | u022890424 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
int k;
scanf("%d", &k);
vector<int> vis(k);
int ans = 1;
int val = 7 % k;
while (val == 0 and !vis[val]) {
vis[val] = 1;
val = (val * 10 + 7) % k;
ans++;
}
if (val == 0)
printf("%d\n", ans);
else
p... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
int k;
scanf("%d", &k);
vector<int> vis(k);
int ans = 1;
int val = 7 % k;
while (val != 0 and !vis[val]) {
vis[val] = 1;
val = (val * 10 + 7) % k;
ans++;
}
if (val == 0)
printf("%d\n", ans);
else
p... | [
"misc.opposites",
"expression.operator.compare.change",
"control_flow.loop.condition.change"
] | 296,463 | 296,464 | u805692198 | cpp |
p02596 | #include <algorithm> //sort(a.begin(), a.end());reverse(a.begin(), a.end());
#include <bits/stdc++.h>
#include <iostream>
#include <math.h> //pow(x,y)=x^y 99999とかの場合+1するif文
#define rep(init, i, n) for (int i = init; i < (n); i++)
#define ll long long
#define rev(s) reverse(s.begin(), s.end())
#define sor(v) sort(v.begi... | #include <algorithm> //sort(a.begin(), a.end());reverse(a.begin(), a.end());
#include <bits/stdc++.h>
#include <iostream>
#include <math.h> //pow(x,y)=x^y 99999とかの場合+1するif文
#define rep(init, i, n) for (int i = init; i < (n); i++)
#define ll long long
#define rev(s) reverse(s.begin(), s.end())
#define sor(v) sort(v.begi... | [
"expression.operation.binary.add"
] | 296,479 | 296,480 | u555627824 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
using vl = vector<ll>;
using vll = vector<vl>;
using Pll = pair<ll, ll>;
#define rep(i, n) for (ll i = 0; i < (ll)(n); i++)
#define all(v) v.begin(), v.end()
#define sz(x) ((int)x.size())
#define pb push_back
#define mp make_pai... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
using vl = vector<ll>;
using vll = vector<vl>;
using Pll = pair<ll, ll>;
#define rep(i, n) for (ll i = 0; i < (ll)(n); i++)
#define all(v) v.begin(), v.end()
#define sz(x) ((int)x.size())
#define pb push_back
#define mp make_pai... | [
"expression.operator.compare.change",
"control_flow.loop.for.condition.change",
"expression.off_by_one",
"expression.operation.binary.change"
] | 296,487 | 296,488 | u201304522 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
ll k;
cin >> k;
ll cul = 0, i;
for (i = 1; i < k; i++) {
cul *= 10;
cul += 7;
cul %= k;
if (cul == 0) {
cout << i << endl;
return 0;
}
}
cout << -1 << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
ll k;
cin >> k;
ll cul = 0, i;
for (i = 1; i < k + 1; i++) {
cul *= 10;
cul += 7;
cul %= k;
if (cul == 0) {
cout << i << endl;
return 0;
}
}
cout << -1 << endl;
return 0;
}
| [
"control_flow.loop.for.condition.change",
"misc.off_by_one"
] | 296,489 | 296,490 | u436528677 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
int k;
cin >> k;
int cul = 0, i;
for (i = 1; i < k; i++) {
cul *= 10;
cul += 7;
cul %= k;
if (cul == 0) {
cout << i << endl;
return 0;
}
}
cout << -1 << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
ll k;
cin >> k;
ll cul = 0, i;
for (i = 1; i < k + 1; i++) {
cul *= 10;
cul += 7;
cul %= k;
if (cul == 0) {
cout << i << endl;
return 0;
}
}
cout << -1 << endl;
return 0;
}
| [
"variable_declaration.type.change",
"control_flow.loop.for.condition.change",
"misc.off_by_one"
] | 296,491 | 296,490 | u436528677 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ar array
ll K;
void solve() {
cin >> K;
ll mod = 7;
int ans = -1;
for (int i = 1; i < K; i++) {
mod = mod % K;
if (mod == 0) {
ans = i;
break;
}
mod = mod * 10 + 7;
}
cout << ans << endl;
}
int mai... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ar array
ll K;
void solve() {
cin >> K;
ll mod = 7;
int ans = -1;
for (int i = 1; i < K + 1; i++) {
mod = mod % K;
if (mod == 0) {
ans = i;
break;
}
mod = mod * 10 + 7;
}
cout << ans << endl;
}
int... | [
"control_flow.loop.for.condition.change",
"misc.off_by_one"
] | 296,493 | 296,494 | u132525821 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ar array
ll K;
void solve() {
cin >> K;
ll mod = 7;
int ans = -1;
for (int i = 1; i < K - 1; i++) {
mod = mod % K;
if (mod == 0) {
ans = i;
break;
}
mod = mod * 10 + 7;
}
cout << ans << endl;
}
int... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ar array
ll K;
void solve() {
cin >> K;
ll mod = 7;
int ans = -1;
for (int i = 1; i < K + 1; i++) {
mod = mod % K;
if (mod == 0) {
ans = i;
break;
}
mod = mod * 10 + 7;
}
cout << ans << endl;
}
int... | [
"misc.opposites",
"expression.operator.arithmetic.change",
"control_flow.loop.for.condition.change",
"expression.operation.binary.change"
] | 296,495 | 296,494 | u132525821 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int K;
cin >> K;
bool F = false;
for (int X = 1, Y = 7; X < K + 2; X++, Y = ((Y * 10) + 7) % K) {
if (Y == 0) {
cout << X << endl;
F = true;
break;
}
}
if (!F)
cout << -1 << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int K;
cin >> K;
bool F = false;
for (int X = 1, Y = 7 % K; X < K + 2; X++, Y = ((Y * 10) + 7) % K) {
if (Y == 0) {
cout << X << endl;
F = true;
break;
}
}
if (!F)
cout << -1 << endl;
} | [
"control_flow.loop.for.initializer.change"
] | 296,510 | 296,511 | u740002394 | cpp |
p02596 | #include <algorithm>
#include <bitset>
#include <chrono>
#include <cmath>
#include <fstream>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <tuple>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#define fio ... | #include <algorithm>
#include <bitset>
#include <chrono>
#include <cmath>
#include <fstream>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <tuple>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#define fio ... | [
"identifier.change",
"assignment.change"
] | 296,514 | 296,515 | u224418230 | cpp |
p02596 | #include <algorithm>
#include <bitset>
#include <chrono>
#include <cmath>
#include <fstream>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <tuple>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#define fio ... | #include <algorithm>
#include <bitset>
#include <chrono>
#include <cmath>
#include <fstream>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <random>
#include <set>
#include <stack>
#include <tuple>
#include <unordered_map>
#include <unordered_set>
#include <vector>
#define fio ... | [] | 296,514 | 296,516 | u224418230 | cpp |
p02596 | #include <bits/stdc++.h>
using namespace std;
int main() {
int n;
cin >> n;
int x = 7 % n;
for (int i = 1; i <= n; ++i) {
if (n == 0) {
cout << i << "\n";
return 0;
}
x = (x * 10 + 7) % n;
}
cout << -1 << "\n";
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int n;
cin >> n;
int x = 7 % n;
for (int i = 1; i <= n; ++i) {
if (x == 0) {
cout << i << "\n";
return 0;
}
x = (x * 10 + 7) % n;
}
cout << -1 << "\n";
}
| [
"identifier.change",
"control_flow.branch.if.condition.change"
] | 296,521 | 296,522 | u486714343 | cpp |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.