problem_id
stringlengths
6
6
language
stringclasses
2 values
original_status
stringclasses
3 values
original_src
stringlengths
19
243k
changed_src
stringlengths
19
243k
change
stringclasses
3 values
i1
int64
0
8.44k
i2
int64
0
8.44k
j1
int64
0
8.44k
j2
int64
0
8.44k
error
stringclasses
270 values
stderr
stringlengths
0
226k
p03096
C++
Runtime Error
#include <algorithm> #include <cmath> #include <cstdio> #include <cstring> #include <iostream> #define rt register int #define l putchar('\n') #define ll long long #define r read() #define p 1000000007 using namespace std; inline ll read() { ll x = 0; char zf = 1; char ch = getchar(); while (ch != '-' && !isdig...
#include <algorithm> #include <cmath> #include <cstdio> #include <cstring> #include <iostream> #define rt register int #define l putchar('\n') #define ll long long #define r read() #define p 1000000007 using namespace std; inline ll read() { ll x = 0; char zf = 1; char ch = getchar(); while (ch != '-' && !isdig...
replace
35
36
35
36
0
p03096
C++
Runtime Error
#include <algorithm> #include <bitset> #include <cmath> #include <functional> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <string> #include <tuple> #include <vector> #define INF 1000000009 #define LINF 1000000000000000009 #define double long double #define all(a) a.beg...
#include <algorithm> #include <bitset> #include <cmath> #include <functional> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <string> #include <tuple> #include <vector> #define INF 1000000009 #define LINF 1000000000000000009 #define double long double #define all(a) a.beg...
replace
45
46
45
46
0
p03096
C++
Runtime Error
// i ll be the king #include <bits/stdc++.h> #define ll long long int #define sync \ ios_base::sync_with_stdio(false); \ cin.tie(NULL) #define input(arr, n) ...
// i ll be the king #include <bits/stdc++.h> #define ll long long int #define sync \ ios_base::sync_with_stdio(false); \ cin.tie(NULL) #define input(arr, n) ...
replace
37
38
37
38
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; using vi = vector<int>; using vb = vector<bool>; using vc = vector<char>; using vs = vector<string>; using vvi = vector<vector<int>>; using vvc = vector<vector<char>>; using pii = pair<int, int>; #define fix10 cout << fixed << setprecision(10); #define rep(i, n) for (int i ...
#include <bits/stdc++.h> using namespace std; using vi = vector<int>; using vb = vector<bool>; using vc = vector<char>; using vs = vector<string>; using vvi = vector<vector<int>>; using vvc = vector<vector<char>>; using pii = pair<int, int>; #define fix10 cout << fixed << setprecision(10); #define rep(i, n) for (int i ...
replace
19
20
19
20
0
p03096
C++
Runtime Error
#include <algorithm> #include <iostream> #include <vector> using namespace std; typedef long long ll; const int mod = 1e+9 + 7; // dpテーブルは 1-indexed ll dp[200005]; int main(void) { ios::sync_with_stdio(false); cin.tie(nullptr); int n; cin >> n; vector<int> c(n); vector<vector<int>> pos(n); // 色がどの位置にあるか...
#include <algorithm> #include <iostream> #include <vector> using namespace std; typedef long long ll; const int mod = 1e+9 + 7; // dpテーブルは 1-indexed ll dp[200005]; int main(void) { ios::sync_with_stdio(false); cin.tie(nullptr); int n; cin >> n; vector<int> c(n); vector<vector<int>> pos(200005); // 色がどの位...
replace
18
19
18
19
0
p03096
C++
Runtime Error
#include <cstdio> #define mod 1000000007 #define maxn 100005 int n, val[maxn], dp[maxn], la[maxn], pos[maxn]; int main() { scanf("%d", &n); for (int i = 1; i <= n; i++) { scanf("%d", &val[i]); la[i] = pos[val[i]], pos[val[i]] = i; } dp[0] = 1; for (int i = 1; i <= n; i++) { dp[i] = dp[i - 1]; ...
#include <cstdio> #define mod 1000000007 #define maxn 200005 int n, val[maxn], dp[maxn], la[maxn], pos[maxn]; int main() { scanf("%d", &n); for (int i = 1; i <= n; i++) { scanf("%d", &val[i]); la[i] = pos[val[i]], pos[val[i]] = i; } dp[0] = 1; for (int i = 1; i <= n; i++) { dp[i] = dp[i - 1]; ...
replace
2
3
2
3
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; // types typedef long long ll; typedef long double ld; typedef pair<int, int> pii; typedef pair<ll, ll> pll; typedef pair<ld, ld> pdd; typedef vector<ll> vll; // macros #define ALL(a) a.begin(), a.end() #define SZ(a) ((int)a.size()) #define FI first #define SE second #def...
#include <bits/stdc++.h> using namespace std; // types typedef long long ll; typedef long double ld; typedef pair<int, int> pii; typedef pair<ll, ll> pll; typedef pair<ld, ld> pdd; typedef vector<ll> vll; // macros #define ALL(a) a.begin(), a.end() #define SZ(a) ((int)a.size()) #define FI first #define SE second #def...
replace
52
53
52
53
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; using ll = long long; #define rep(i, n) for (ll i = 0; i < (ll)(n); i++) #define rep2(i, s, n) for (ll i = (s); i < (ll)(n); i++) #define all(v) v.begin(), v.end() #define sz(v) v.size() #define INF 100000000000000 // 10^14 template <typename T> bool chmax(T &a, const T &b)...
#include <bits/stdc++.h> using namespace std; using ll = long long; #define rep(i, n) for (ll i = 0; i < (ll)(n); i++) #define rep2(i, s, n) for (ll i = (s); i < (ll)(n); i++) #define all(v) v.begin(), v.end() #define sz(v) v.size() #define INF 100000000000000 // 10^14 template <typename T> bool chmax(T &a, const T &b)...
insert
75
75
75
76
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; // #define DEBUG_MODE #define endl '\n' #ifdef DEBUG_MODE #define DEBUG(X) debug_func(X, #X) #define DEBUG_ENDL endl << flush #define DEBUG_SEPARATOR_LINE cout << "=================\n" #else #define DEBUG(X) 0 #define DEBUG_ENDL 0 #define DEBUG_SEPARATOR_LINE 0 #endif #defi...
#include <bits/stdc++.h> using namespace std; // #define DEBUG_MODE #define endl '\n' #ifdef DEBUG_MODE #define DEBUG(X) debug_func(X, #X) #define DEBUG_ENDL endl << flush #define DEBUG_SEPARATOR_LINE cout << "=================\n" #else #define DEBUG(X) 0 #define DEBUG_ENDL 0 #define DEBUG_SEPARATOR_LINE 0 #endif #defi...
replace
75
76
75
76
0
p03096
C++
Runtime Error
#include <algorithm> #include <cassert> #include <cctype> #include <chrono> #define _USE_MATH_DEFINES #include <cmath> #include <cstdio> #include <cstring> #include <ctime> #include <deque> #include <functional> #include <iostream> #include <map> #include <queue> #include <random> #include <set> #include <sstream> #inc...
#include <algorithm> #include <cassert> #include <cctype> #include <chrono> #define _USE_MATH_DEFINES #include <cmath> #include <cstdio> #include <cstring> #include <ctime> #include <deque> #include <functional> #include <iostream> #include <map> #include <queue> #include <random> #include <set> #include <sstream> #inc...
replace
36
37
36
37
0
p03096
C++
Runtime Error
#include <algorithm> #include <array> #include <bitset> #include <cmath> #include <complex> #include <cstdio> #include <deque> #include <float.h> #include <functional> #include <iomanip> #include <iostream> #include <limits.h> #include <list> #include <map> #include <numeric> #include <queue> #include <set> #include <s...
#include <algorithm> #include <array> #include <bitset> #include <cmath> #include <complex> #include <cstdio> #include <deque> #include <float.h> #include <functional> #include <iomanip> #include <iostream> #include <limits.h> #include <list> #include <map> #include <numeric> #include <queue> #include <set> #include <s...
replace
111
112
111
112
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define MOD 1000000007 int main() { long Nc; cin >> Nc; vector<long> C; for (long i = 0; i < Nc; i++) { long c; cin >> c; c--; if (i == 0 || c != C[C.size() - 1]) C.push_back(c); } long N = C.size(); vector<long> DP(N, 1), L(Nc, 0); fo...
#include <bits/stdc++.h> using namespace std; #define MOD 1000000007 int main() { long Nc; cin >> Nc; vector<long> C; for (long i = 0; i < Nc; i++) { long c; cin >> c; c--; if (i == 0 || c != C[C.size() - 1]) C.push_back(c); } long N = C.size(); Nc = 200000; vector<long> DP(N, 1),...
insert
15
15
15
16
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; const long long MOD = 1000000007; typedef long long ll; // -9,223,372,036,854,775,808 から 9,223,372,036,854,775,807 template <class T> using vec = std::vector<T>; template <class T> using vec2 = vec<vec<T>>; template <class T> using vec3 = vec<vec<vec<T>>>; // #defin...
#include <bits/stdc++.h> using namespace std; const long long MOD = 1000000007; typedef long long ll; // -9,223,372,036,854,775,808 から 9,223,372,036,854,775,807 template <class T> using vec = std::vector<T>; template <class T> using vec2 = vec<vec<T>>; template <class T> using vec3 = vec<vec<vec<T>>>; // #defin...
replace
196
197
196
197
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define dump(...) \ do { \ print_vars(cout << "# " << #__VA_ARGS__ << '=', __VA_ARGS__); \ cout << endl; ...
#include <bits/stdc++.h> using namespace std; #define dump(...) \ do { \ print_vars(cout << "# " << #__VA_ARGS__ << '=', __VA_ARGS__); \ cout << endl; ...
replace
156
157
156
157
0
p03096
C++
Runtime Error
#include <algorithm> #include <cmath> #include <complex> #include <cstdio> #include <cstdlib> #include <cstring> #include <deque> #include <functional> #include <iomanip> #include <iostream> #include <list> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <string> #include <tu...
#include <algorithm> #include <cmath> #include <complex> #include <cstdio> #include <cstdlib> #include <cstring> #include <deque> #include <functional> #include <iomanip> #include <iostream> #include <list> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <string> #include <tu...
replace
43
44
43
44
0
p03096
C++
Runtime Error
#if 1 #include <algorithm> #include <climits> #include <cmath> #include <functional> #include <iostream> #include <numeric> #include <set> #include <string> #include <unordered_map> #include <unordered_set> #include <vector> using namespace std; #define int long long constexpr int MOD = 1000000007; constexpr int INF =...
#if 1 #include <algorithm> #include <climits> #include <cmath> #include <functional> #include <iostream> #include <numeric> #include <set> #include <string> #include <unordered_map> #include <unordered_set> #include <vector> using namespace std; #define int long long constexpr int MOD = 1000000007; constexpr int INF =...
replace
48
49
48
49
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; const int mod = 1e9 + 7; int add(int &x, int y) { x += y; if (x >= mod) { x -= mod; } } int main() { ios::sync_with_stdio(false); cin.tie(0); int n; cin >> n; vector<int> a(n); for (int i = 0; i < n; i++) { cin >> a[i]; a[i]--; } a.erase...
#include <bits/stdc++.h> using namespace std; const int mod = 1e9 + 7; int add(int &x, int y) { x += y; if (x >= mod) { x -= mod; } } int main() { ios::sync_with_stdio(false); cin.tie(0); int n; cin >> n; vector<int> a(n); for (int i = 0; i < n; i++) { cin >> a[i]; a[i]--; } a.erase...
replace
24
25
24
25
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> #define Set(a, b) memset(a, b, sizeof(a)) using namespace std; const int N = 1e5 + 10; const int mod = 1e9 + 7; template <typename T> inline void init(T &x) { x = 0; char ch = getchar(); bool t = 0; for (; ch > '9' || ch < '0'; ch = getchar()) if (ch == '-') t = 1; for (; ch...
#include <bits/stdc++.h> #define Set(a, b) memset(a, b, sizeof(a)) using namespace std; const int N = 2e5 + 10; const int mod = 1e9 + 7; template <typename T> inline void init(T &x) { x = 0; char ch = getchar(); bool t = 0; for (; ch > '9' || ch < '0'; ch = getchar()) if (ch == '-') t = 1; for (; ch...
replace
3
4
3
4
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define FOR(i, a, b) for (int i = (a); i < (b); ++i) #define FORR(i, a, b) for (int i = (a); i > (b); --i) #define REP(i, n) for (int i = 0; i < (n); ++i) #define REPR(i, n) for (int i = n; i >= 0; i--) #define FOREACH(x, a) for (auto &(x) : (a)) #define VECCIN(x) ...
#include <bits/stdc++.h> using namespace std; #define FOR(i, a, b) for (int i = (a); i < (b); ++i) #define FORR(i, a, b) for (int i = (a); i > (b); --i) #define REP(i, n) for (int i = 0; i < (n); ++i) #define REPR(i, n) for (int i = n; i >= 0; i--) #define FOREACH(x, a) for (auto &(x) : (a)) #define VECCIN(x) ...
replace
59
60
59
60
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < n; i++) #define rep1(i, n) for (int i = 1; i < n; i++) #define all(v) (v).begin(), (v).end() #define decimal fixed << setprecision(20) #define fastcin() \ cin.tie(0); ...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < n; i++) #define rep1(i, n) for (int i = 1; i < n; i++) #define all(v) (v).begin(), (v).end() #define decimal fixed << setprecision(20) #define fastcin() \ cin.tie(0); ...
replace
94
95
94
95
0
p03096
C++
Runtime Error
// #pragma GCC optimize ("-O3") #include <bits/stdc++.h> using namespace std; //@起動時 struct initon { initon() { cin.tie(0); ios::sync_with_stdio(false); cout.setf(ios::fixed); cout.precision(16); srand((unsigned)clock() + (unsigned)time(NULL)); }; } __initon; // 衝突対策 #define ws ___ws //@必須構造 st...
// #pragma GCC optimize ("-O3") #include <bits/stdc++.h> using namespace std; //@起動時 struct initon { initon() { cin.tie(0); ios::sync_with_stdio(false); cout.setf(ios::fixed); cout.precision(16); srand((unsigned)clock() + (unsigned)time(NULL)); }; } __initon; // 衝突対策 #define ws ___ws //@必須構造 st...
replace
2,318
2,320
2,318
2,320
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int a[100007]; int b[100007]; long long dp[100007]; long long sum[100007]; const long long mod = 1e9 + 7; int main() { dp[0] = 1; int n; scanf("%d", &n); for (int i = 1; i <= n; i++) scanf("%d", &a[i]); int cnt = 0; for (int i = 1; i <= n; i++) { if (a[i...
#include <bits/stdc++.h> using namespace std; int a[200007]; int b[200007]; long long dp[200007]; long long sum[200007]; const long long mod = 1e9 + 7; int main() { dp[0] = 1; int n; scanf("%d", &n); for (int i = 1; i <= n; i++) scanf("%d", &a[i]); int cnt = 0; for (int i = 1; i <= n; i++) { if (a[i...
replace
2
6
2
6
0
p03096
C++
Runtime Error
#include <algorithm> #include <cassert> #include <cmath> #include <cstdio> #include <deque> #include <functional> #include <iomanip> #include <iostream> #include <iterator> #include <limits> #include <map> #include <numeric> #include <queue> #include <set> #include <sstream> #include <stack> #include <string> #include ...
#include <algorithm> #include <cassert> #include <cmath> #include <cstdio> #include <deque> #include <functional> #include <iomanip> #include <iostream> #include <iterator> #include <limits> #include <map> #include <numeric> #include <queue> #include <set> #include <sstream> #include <stack> #include <string> #include ...
replace
143
144
143
144
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> #define mp make_pair #define all(vec) vec.begin(), vec.end() using namespace std; using ll = long long; using P = pair<ll, ll>; const ll INF = 1LL << 30; const ll LINF = 1LL << 60; const double eps = 1e-9; const ll MOD = 1000000007LL; template <typename T> void chmin(T &a, T b) { a = min(a, b);...
#include <bits/stdc++.h> #define mp make_pair #define all(vec) vec.begin(), vec.end() using namespace std; using ll = long long; using P = pair<ll, ll>; const ll INF = 1LL << 30; const ll LINF = 1LL << 60; const double eps = 1e-9; const ll MOD = 1000000007LL; template <typename T> void chmin(T &a, T b) { a = min(a, b);...
replace
30
31
30
31
0
p03096
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; using ll = long long; #define MOD 1000000007 int N; vector<int> C; vector<int> memo; vector<int> nearest; vector<int> ind; int f(int i) { if (i >= nearest.size()) return 1; if (memo[i] != -1) return memo[i]; if (nearest[i] == -1) { return memo[i] = f(i ...
#include <bits/stdc++.h> using namespace std; using ll = long long; #define MOD 1000000007 int N; vector<int> C; vector<int> memo; vector<int> nearest; vector<int> ind; int f(int i) { if (i >= nearest.size()) return 1; if (memo[i] != -1) return memo[i]; if (nearest[i] == -1) { return memo[i] = f(i ...
replace
31
32
31
32
0
p03097
C++
Time Limit Exceeded
#include <bits/stdc++.h> #define fr(i, n) for (int i = 0; i < (n); ++i) #define foor(i, a, b) for (int i = (a); i <= (b); ++i) #define rf(i, n) for (int i = (n); i--;) #define roof(i, b, a) for (int i = (b); i >= (a); --i) #define elsif else if #define all(x) x.begin(), x.end() #define Sort(x) sort(all(x)) #define Reve...
#include <bits/stdc++.h> #define fr(i, n) for (int i = 0; i < (n); ++i) #define foor(i, a, b) for (int i = (a); i <= (b); ++i) #define rf(i, n) for (int i = (n); i--;) #define roof(i, b, a) for (int i = (b); i >= (a); --i) #define elsif else if #define all(x) x.begin(), x.end() #define Sort(x) sort(all(x)) #define Reve...
insert
548
548
548
553
TLE
p03097
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int n; int dfs(int pos, int cnt, int a, int bit, vector<int> &tmp) { int keta = (pos + cnt) % n; if (cnt == 0) { if ((bit >> cnt) & 1) return a; else { a ^= (1 << keta); tmp.push_back(a); return a; } } else { if ((bit >> cnt) &...
#include <bits/stdc++.h> using namespace std; int n; int dfs(int pos, int cnt, int a, int bit, vector<int> &tmp) { int keta = (pos + cnt) % n; if (cnt == 0) { if ((bit >> cnt) & 1) return a; else { a ^= (1 << keta); tmp.push_back(a); return a; } } else { if ((bit >> cnt) &...
replace
37
38
37
38
0
p03097
C++
Runtime Error
/* ЗАПУСКАЕМ ░ГУСЯ░▄▀▀▀▄░РАБОТЯГУ░░ ▄███▀░◐░░░▌░░░░░░░ ░░░░▌░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▌░░░░░▐▄▄░░░░░ ░░░░▌░░░░▄▀▒▒▀▀▀▀▄ ░░░▐░░░░▐▒▒▒▒▒▒▒▒▀▀▄ ░░░▐░░░░▐▄▒▒▒▒▒▒▒▒▒▒▀▄ ░░░░▀▄░░░░▀▄...
/* ЗАПУСКАЕМ ░ГУСЯ░▄▀▀▀▄░РАБОТЯГУ░░ ▄███▀░◐░░░▌░░░░░░░ ░░░░▌░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▐░░░░░▐░░░░░░░ ░░░░▌░░░░░▐▄▄░░░░░ ░░░░▌░░░░▄▀▒▒▀▀▀▀▄ ░░░▐░░░░▐▒▒▒▒▒▒▒▒▀▀▄ ░░░▐░░░░▐▄▒▒▒▒▒▒▒▒▒▒▀▄ ░░░░▀▄░░░░▀▄...
insert
103
103
103
107
0
p03097
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; template <class T, class U> ostream &operator<<(ostream &os, const pair<T, U> &p) { os << "(" << p.first << "," << p.second << ")"; return os; } #ifdef __LOCAL #define debug(x) cerr << __LINE__ << ": " << #x << " = " << (x) << '\n' #define debugArray(x, n) ...
#include <bits/stdc++.h> using namespace std; template <class T, class U> ostream &operator<<(ostream &os, const pair<T, U> &p) { os << "(" << p.first << "," << p.second << ")"; return os; } #ifdef __LOCAL #define debug(x) cerr << __LINE__ << ": " << #x << " = " << (x) << '\n' #define debugArray(x, n) ...
insert
57
57
57
58
TLE
p03097
C++
Runtime Error
/** * author: tourist * created: 16.03.2019 15:29:11 **/ #include <bits/stdc++.h> using namespace std; int remove_bit(int x, int j) { int low = x & ((1 << j) - 1); return ((x >> (j + 1)) << j) + low; } int insert_bit(int x, int j, int v) { int low = x & ((1 << j) - 1); return ((x >> j) << (j + 1)) ...
/** * author: tourist * created: 16.03.2019 15:29:11 **/ #include <bits/stdc++.h> using namespace std; int remove_bit(int x, int j) { int low = x & ((1 << j) - 1); return ((x >> (j + 1)) << j) + low; } int insert_bit(int x, int j, int v) { int low = x & ((1 << j) - 1); return ((x >> j) << (j + 1)) ...
insert
29
29
29
35
0
p03097
C++
Runtime Error
#include <bits/stdc++.h> typedef long long LL; #define SZ(X) ((int)(X).size()) #define ALL(X) (X).begin(), (X).end() #define REP(I, N) for (int I = 0; I < (N); ++I) #define REPP(I, A, B) for (int I = (A); I < (B); ++I) #define RI(X) scanf("%d", &(X)) #define RII(X, Y) scanf("%d%d", &(X), &(Y)) #define RIII(X, Y, Z) sca...
#include <bits/stdc++.h> typedef long long LL; #define SZ(X) ((int)(X).size()) #define ALL(X) (X).begin(), (X).end() #define REP(I, N) for (int I = 0; I < (N); ++I) #define REPP(I, A, B) for (int I = (A); I < (B); ++I) #define RI(X) scanf("%d", &(X)) #define RII(X, Y) scanf("%d%d", &(X), &(Y)) #define RIII(X, Y, Z) sca...
insert
73
73
73
77
0
p03097
C++
Runtime Error
#pragma GCC optimize("Ofast") #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; using ll = long long; using ull = unsigned long long; using pii = pair<int, int>; using pll = pair<long long, long long>; #define rep(i, n...
#pragma GCC optimize("Ofast") #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; using ll = long long; using ull = unsigned long long; using pii = pair<int, int>; using pll = pair<long long, long long>; #define rep(i, n...
replace
36
37
36
37
0
p03097
C++
Time Limit Exceeded
#include <algorithm> #include <cmath> #include <cstdio> #include <iostream> #include <map> #include <string> #include <vector> using namespace std; const int N = 1e6; int n, A, B; int a[N]; int count(int x) { int sum = 0; while (x) { sum += (x & 1); x >>= 1; } return sum; } void work(int *a, int n, int ...
#include <algorithm> #include <cmath> #include <cstdio> #include <iostream> #include <map> #include <string> #include <vector> using namespace std; const int N = 1e6; int n, A, B; int a[N]; int count(int x) { int sum = 0; while (x) { sum += (x & 1); x >>= 1; } return sum; } void work(int *a, int n, int ...
replace
55
56
55
56
TLE
p03097
C++
Runtime Error
#include <algorithm> #include <bitset> #include <cassert> #include <cmath> #include <complex> #include <cstdio> #include <cstring> #include <ctime> #include <fstream> #include <functional> #include <iomanip> #include <iostream> #include <map> #include <numeric> #include <queue> #include <random> #include <set> #include...
#include <algorithm> #include <bitset> #include <cassert> #include <cmath> #include <complex> #include <cstdio> #include <cstring> #include <ctime> #include <fstream> #include <functional> #include <iomanip> #include <iostream> #include <map> #include <numeric> #include <queue> #include <random> #include <set> #include...
insert
107
107
107
108
0
p03097
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int pc(int i) { return __builtin_popcount(i); } int arr[1 << 17]; int rmbit(unsigned n, int i) { return ((n << (32 - i)) >> (32 - i)) | (((n >> (i + 1))) << i); } int addbit(unsigned n, int i, bool p) { unsigned t = (n >> i) << (i + 1), s = (n << (32 - i)) >> (32 - i); ...
#include <bits/stdc++.h> using namespace std; int pc(int i) { return __builtin_popcount(i); } int arr[1 << 17]; int getl(int n, int i) { return (n >> (i + 1)) << (i + 1); } int getr(int n, int i) { return n ^ ((n >> i) << i); } int rmbit(int n, int i) { return (getl(n, i) >> 1) | getr(n, i); } int addbit(int n, int i, ...
replace
4
13
4
9
0
p03097
C++
Runtime Error
#include <algorithm> #include <cstdio> #include <cstring> #define lowbit(_A) ((_A) & (-(_A))) int n; int cnt; int fr[166666]; int ne[333333]; int to[333333]; void add(int a, int b) { ne[++cnt] = fr[a], fr[a] = cnt, to[cnt] = b; ne[++cnt] = fr[b], fr[b] = cnt, to[cnt] = a; } void dfs(int S, int T, int s, int cnt)...
#include <algorithm> #include <cstdio> #include <cstring> #define lowbit(_A) ((_A) & (-(_A))) int n; int cnt; int fr[166666]; int ne[333333]; int to[333333]; void add(int a, int b) { ne[++cnt] = fr[a], fr[a] = cnt, to[cnt] = b; ne[++cnt] = fr[b], fr[b] = cnt, to[cnt] = a; } void dfs(int S, int T, int s, int cnt)...
insert
40
40
40
41
0
p03097
C++
Runtime Error
#include <algorithm> #include <iostream> #include <vector> using namespace std; void print(int x) { for (int i = 7; i >= 0; i--) cout << (x >> i & 1); cout << endl; } int main() { int N, A, B; cin >> N >> A >> B; auto count = [&](int x) { int r = 0; for (int i = 0; i < N; i++) r += x >> i...
#include <algorithm> #include <iostream> #include <vector> using namespace std; void print(int x) { for (int i = 7; i >= 0; i--) cout << (x >> i & 1); cout << endl; } int main() { int N, A, B; cin >> N >> A >> B; auto count = [&](int x) { int r = 0; for (int i = 0; i < N; i++) r += x >> i...
replace
33
47
33
37
0
p03097
C++
Runtime Error
#include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <algorithm> #include <complex> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <string> #include <unordered_map> #include <unordered_set> #include <vector> #include <casser...
#include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <algorithm> #include <complex> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <string> #include <unordered_map> #include <unordered_set> #include <vector> #include <casser...
replace
134
135
134
135
0
p03097
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { #ifdef wxh010910 freopen("input.txt", "r", stdin); #endif ios::sync_with_stdio(false); cin.tie(0); cout.tie(0); int n, a, b; cin >> n >> a >> b; int k = __builtin_popcount(a ^ b); if (k % 2 == 0) { cout << "NO" << "\n"; return...
#include <bits/stdc++.h> using namespace std; int main() { #ifdef wxh010910 freopen("input.txt", "r", stdin); #endif ios::sync_with_stdio(false); cin.tie(0); cout.tie(0); int n, a, b; cin >> n >> a >> b; int k = __builtin_popcount(a ^ b); if (k % 2 == 0) { cout << "NO" << "\n"; return...
insert
22
22
22
23
0
p03097
C++
Runtime Error
#include <bits/stdc++.h> #define maxn 100005 using namespace std; inline int read() { int x = 0, c; while (!isdigit(c = getchar())) ; while (x = x * 10 + c - '0', isdigit(c = getchar())) ; return x; } int cnt[1 << 18], ans[18][1 << 17], n, A, B; void solve(int k, int A, int B, int *a, int l, int r) { ...
#include <bits/stdc++.h> #define maxn 100005 using namespace std; inline int read() { int x = 0, c; while (!isdigit(c = getchar())) ; while (x = x * 10 + c - '0', isdigit(c = getchar())) ; return x; } int cnt[1 << 18], ans[18][1 << 17], n, A, B; void solve(int k, int A, int B, int *a, int l, int r) { ...
replace
20
22
20
22
0
p03097
C++
Runtime Error
#include <bits/stdc++.h> #define fi first #define se second #define mp make_pair #define pb push_back #define eb emplace_back using namespace std; typedef long long ll; typedef pair<int, int> ii; const int maxn = 1 << 17; int N, A, B; void go(int s, int t, int mask) { if (__builtin_popcount(mask) == N - 1) { ...
#include <bits/stdc++.h> #define fi first #define se second #define mp make_pair #define pb push_back #define eb emplace_back using namespace std; typedef long long ll; typedef pair<int, int> ii; const int maxn = 1 << 17; int N, A, B; void go(int s, int t, int mask) { if (__builtin_popcount(mask) == N - 1) { ...
replace
29
31
29
31
0
p03097
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define FOR(i, a, b) for (int i = (a); i < (b); ++i) #define rep(i, n) FOR(i, 0, n) #define pb emplace_back typedef long long ll; typedef pair<int, int> pint; int n, a, b; vector<int> ret; void dfs(int l, int r, int mask) { if (mask & (mask - 1) == 0) { ret.pb(l); ...
#include <bits/stdc++.h> using namespace std; #define FOR(i, a, b) for (int i = (a); i < (b); ++i) #define rep(i, n) FOR(i, 0, n) #define pb emplace_back typedef long long ll; typedef pair<int, int> pint; int n, a, b; vector<int> ret; void dfs(int l, int r, int mask) { if ((mask & (mask - 1)) == 0) { ret.pb(l); ...
replace
11
12
11
12
0
p03097
C++
Runtime Error
#include <bitset> #include <iostream> #include <vector> using namespace std; int n; int a, b; void dfs(vector<int> &ans, int a, int b, int cn, int mask) { if (cn == 1) { ans.push_back(a); ans.push_back(b); return; } int c, d; for (int i = 0; i < n; i++) { if (!(mask & (1 << i)) && ((a ^ b) ...
#include <bitset> #include <iostream> #include <vector> using namespace std; int n; int a, b; void dfs(vector<int> &ans, int a, int b, int cn, int mask) { if (cn == 1) { ans.push_back(a); ans.push_back(b); return; } int c, d; for (int i = 0; i < n; i++) { if (!(mask & (1 << i)) && ((a ^ b) ...
replace
32
34
32
34
0
p03097
C++
Runtime Error
#pragma GCC target("avx2") #pragma GCC optimization("O3") #pragma GCC optimization("unroll-loops") #include <algorithm> #include <assert.h> #include <bitset> #include <cfloat> #include <complex> #include <deque> #include <fstream> #include <functional> #include <iomanip> #include <iostream> #include <limits.h> #include...
#pragma GCC target("avx2") #pragma GCC optimization("O3") #pragma GCC optimization("unroll-loops") #include <algorithm> #include <assert.h> #include <bitset> #include <cfloat> #include <complex> #include <deque> #include <fstream> #include <functional> #include <iomanip> #include <iostream> #include <limits.h> #include...
replace
82
83
82
83
0
p03097
C++
Time Limit Exceeded
#include <bits/stdc++.h> // iostream is too mainstream #include <cstdio> // bitch please #include <algorithm> #include <cmath> #include <cstdlib> #include <iomanip> #include <iostream> #include <list> #include <map> #include <queue> #include <set> #include <stack> #include <time.h> #include <vector> #define dibs reserv...
#include <bits/stdc++.h> // iostream is too mainstream #include <cstdio> // bitch please #include <algorithm> #include <cmath> #include <cstdlib> #include <iomanip> #include <iostream> #include <list> #include <map> #include <queue> #include <set> #include <stack> #include <time.h> #include <vector> #define dibs reserv...
insert
70
70
70
71
TLE
p03097
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; typedef long double ld; typedef long long ll; typedef pair<double, double> pdd; typedef vector<double> vd; typedef vector<vd> vvd; typedef vector<ll> vl; typedef vector<vl> vvl; typedef pair<int, int> pii; typedef vector<pii> vii; typedef vector<int> vi; typedef vector<vi> ...
#include <bits/stdc++.h> using namespace std; typedef long double ld; typedef long long ll; typedef pair<double, double> pdd; typedef vector<double> vd; typedef vector<vd> vvd; typedef vector<ll> vl; typedef vector<vl> vvl; typedef pair<int, int> pii; typedef vector<pii> vii; typedef vector<int> vi; typedef vector<vi> ...
replace
35
36
35
36
0
p03097
C++
Runtime Error
#include <cassert> #include <iostream> #include <vector> using namespace std; int N, A, B; vector<int> ans; vector<int> dfs(int start, int goal, int len) { if (len == 1) return (vector<int>){start, goal}; int x = 0; for (int i = 0; i < len; i++) { if ((start ^ goal) & (1 << i)) { x = i; brea...
#include <cassert> #include <iostream> #include <vector> using namespace std; int N, A, B; vector<int> ans; vector<int> dfs(int start, int goal, int len) { if (len == 1) return (vector<int>){start, goal}; int x = 0; for (int i = 0; i < len; i++) { if ((start ^ goal) & (1 << i)) { x = i; brea...
replace
67
68
67
68
0
p03097
C++
Time Limit Exceeded
#include <bits/stdc++.h> #define rep(i, a, b) for (int i = (a); i <= (b); i++) #define per(i, a, b) for (int i = (a); i >= (b); i--) #define REP(i, n) for (int i = (0); i < (n); i++) #define fi first #define se second #define pb push_back #define mp make_pair using namespace std; typedef pair<int, int> pii; typedef vec...
#include <bits/stdc++.h> #define rep(i, a, b) for (int i = (a); i <= (b); i++) #define per(i, a, b) for (int i = (a); i >= (b); i--) #define REP(i, n) for (int i = (0); i < (n); i++) #define fi first #define se second #define pb push_back #define mp make_pair using namespace std; typedef pair<int, int> pii; typedef vec...
insert
30
30
30
31
TLE
p03098
C++
Runtime Error
#include <algorithm> #include <cstdio> #include <cstring> #include <vector> #define fo(i, a, b) for (int i = a; i <= b; i++) #define fd(i, a, b) for (int i = a; i >= b; i--) using namespace std; const int N = 1e5 + 5; typedef vector<int> vec; int n, k, c[N]; bool vis[N]; vec a[7], A, p, q; vec inv(vec a) { vec b;...
#include <algorithm> #include <cstdio> #include <cstring> #include <vector> #define fo(i, a, b) for (int i = a; i <= b; i++) #define fd(i, a, b) for (int i = a; i >= b; i--) using namespace std; const int N = 1e5 + 5; typedef vector<int> vec; int n, k, c[N]; bool vis[N]; vec a[7], A, p, q; vec inv(vec a) { vec b;...
replace
70
71
70
71
0
p03098
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define int long long #define double long double #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define reps(i, n) for (int i = 1; i <= (int)(n); i++) #define all(x) (x).begin(), (x).end() #define uniq(x) (x).erase(unique(all(x)), (x).end()); #define bit(n) (1LL << (...
#include <bits/stdc++.h> using namespace std; #define int long long #define double long double #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define reps(i, n) for (int i = 1; i <= (int)(n); i++) #define all(x) (x).begin(), (x).end() #define uniq(x) (x).erase(unique(all(x)), (x).end()); #define bit(n) (1LL << (...
replace
126
127
126
127
-6
Fatal glibc error: malloc assertion failure in sysmalloc: (old_top == initial_top (av) && old_size == 0) || ((unsigned long) (old_size) >= MINSIZE && prev_inuse (old_top) && ((unsigned long) old_end & (pagesize - 1)) == 0)
p03099
C++
Runtime Error
#include <algorithm> #include <cstdio> #include <cstring> #include <queue> using namespace std; int S = 0, T; int N; struct edge { int s, t, cap; long long v; int nxt; } e[50005]; int e_cnt, last[405]; void addedge(int u, int v, int cap, long long l) { e[e_cnt] = (edge){u, v, cap, l, last[u]}; last[u] = e_cnt...
#include <algorithm> #include <cstdio> #include <cstring> #include <queue> using namespace std; int S = 0, T; int N; struct edge { int s, t, cap; long long v; int nxt; } e[50005]; int e_cnt, last[405]; void addedge(int u, int v, int cap, long long l) { e[e_cnt] = (edge){u, v, cap, l, last[u]}; last[u] = e_cnt...
replace
69
70
69
70
TLE
p03099
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; #define N 710 #define M 200010 #define int long long #define INF 4611686018427387904LL inline int read() { int x = 0; char ch = getchar(); while (!isdigit(ch)) ch = getchar(); while (isdigit(ch)) x = x * 10 + ch - '0', ch = getchar(); return x; } struct Po...
#include <bits/stdc++.h> using namespace std; #define N 2010 #define M 200010 #define int long long #define INF 4611686018427387904LL inline int read() { int x = 0; char ch = getchar(); while (!isdigit(ch)) ch = getchar(); while (isdigit(ch)) x = x * 10 + ch - '0', ch = getchar(); return x; } struct P...
replace
2
3
2
3
TLE
p03099
C++
Runtime Error
#include <algorithm> #include <bitset> #include <cassert> #include <cctype> #include <climits> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <functional> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <...
#include <algorithm> #include <bitset> #include <cassert> #include <cctype> #include <climits> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <functional> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <...
replace
56
57
56
57
0
p03099
C++
Runtime Error
#include <algorithm> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <vector> #define sqr(x) ((x) * (x)) #define fz1(i, n) for ((i) = 1; (i) <= (n); (i)++) #define fd...
#include <algorithm> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <ctime> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <vector> #define sqr(x) ((x) * (x)) #define fz1(i, n) for ((i) = 1; (i) <= (n); (i)++) #define fd...
replace
66
68
66
68
0
p03099
C++
Time Limit Exceeded
#include <bits/stdc++.h> #define Fail puts("NO"), exit(0); #define eps 1e-10 #define maxn 505 #define maxm 100010 #define inf 1000000007 #define mod 1000000007 #define pi acos(-1) #define mp(x, y) make_pair(x, y) #define fi first #define se second using namespace std; typedef long long ll; typedef unsigned int uint; ty...
#include <bits/stdc++.h> #define Fail puts("NO"), exit(0); #define eps 1e-10 #define maxn 505 #define maxm 100010 #define inf 1000000007 #define mod 1000000007 #define pi acos(-1) #define mp(x, y) make_pair(x, y) #define fi first #define se second using namespace std; typedef long long ll; typedef unsigned int uint; ty...
replace
41
43
41
43
TLE
p03099
C++
Runtime Error
#include <algorithm> #include <cstdio> #include <cstring> #include <iostream> #define fo(i, j, l) for (int i = j; i <= l; ++i) #define fd(i, j, l) for (int i = j; i >= l; --i) using namespace std; typedef long long ll; const ll N = 600, M = N * 10, maxn = 1e18; bool bz[N]; int x[N], y[N]; ll v[N]; int la[N], lb[M], ...
#include <algorithm> #include <cstdio> #include <cstring> #include <iostream> #define fo(i, j, l) for (int i = j; i <= l; ++i) #define fd(i, j, l) for (int i = j; i >= l; --i) using namespace std; typedef long long ll; const ll N = 1000, M = N * 50, maxn = 1e18; bool bz[N]; int x[N], y[N]; ll v[N]; int la[N], lb[M],...
replace
10
11
10
11
0
p03099
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ref(i, x, y) for (int i = x; i <= y; ++i) #define def(i, x, y) for (int i = x; i >= y; --i) #define fi first #define se second #define int long long #define pb push_back typedef long long LL; const int N = 221; int n, m; int lx[2][N], ly[2][N]; struct dot { int x,...
#include <bits/stdc++.h> using namespace std; #define ref(i, x, y) for (int i = x; i <= y; ++i) #define def(i, x, y) for (int i = x; i >= y; --i) #define fi first #define se second #define int long long #define pb push_back typedef long long LL; const int N = 421; int n, m; int lx[2][N], ly[2][N]; struct dot { int x,...
replace
9
10
9
10
0
p03099
C++
Runtime Error
#include <bits/stdc++.h> #define N 100 #define M 400 #define V 200 #define E 1000 #define INF 1000000000000000000LL using namespace std; int n; struct jewel { int x, y; long long v; } J[N]; struct table { int n, a[N]; void add(int x) { a[++n] = x; } void su() { sort(a + 1, a + n + 1); n = unique(a + 1...
#include <bits/stdc++.h> #define N 1000 #define M 1000 #define V 1000 #define E 10000 #define INF 1000000000000000000LL using namespace std; int n; struct jewel { int x, y; long long v; } J[N]; struct table { int n, a[N]; void add(int x) { a[++n] = x; } void su() { sort(a + 1, a + n + 1); n = unique(a...
replace
1
5
1
5
0
p03099
C++
Runtime Error
#include <algorithm> #include <cstdio> #include <cstring> #include <queue> #define ll long long using namespace std; const int INF = 2147483647; struct Edge { int to, nxt; int flow; ll cost; } e[10005]; int n, m, s, t, edgenum, head[1005], f[1005], pre[1005], x[85], y[85], a[325], b[325], l1[85], r1[85], l2[8...
#include <algorithm> #include <cstdio> #include <cstring> #include <queue> #define ll long long using namespace std; const int INF = 2147483647; struct Edge { int to, nxt; int flow; ll cost; } e[100005]; int n, m, s, t, edgenum, head[1005], f[1005], pre[1005], x[85], y[85], a[325], b[325], l1[85], r1[85], l2[...
replace
11
12
11
12
0
p03099
C++
Runtime Error
#include <cstdio> #include <cstring> #include <iostream> using namespace std; typedef long long ll; const ll N = 1e4 + 10, inf = 1e18; ll w[N], ne[N], la[N], len[N], cst[N], t = 1; ll d[N], dep[N], s[N], ans, S, T, vis[N], cur[N]; void alink(ll x, ll y, ll z, ll l) { w[++t] = y; ne[t] = la[x]; la[x] = t; len[t]...
#include <cstdio> #include <cstring> #include <iostream> using namespace std; typedef long long ll; const ll N = 1005, inf = 1e18, M = 1e6; ll w[M], ne[M], la[M], len[M], cst[M], t = 1; ll d[M], dep[M], s[M], ans, S, T, vis[M], cur[M]; void alink(ll x, ll y, ll z, ll l) { w[++t] = y; ne[t] = la[x]; la[x] = t; l...
replace
5
8
5
8
0
p03099
C++
Runtime Error
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define rep1(i, n) for (int i = 1; i <= (int)(n); i++) #define MP make_pair using namespace std; typedef long long LL; typedef pair<int, int> PII; const LL INF = 0x3f3f3f3f3f3f3f; namespace flow { const int MAXN = 400; struct edge { int t...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define rep1(i, n) for (int i = 1; i <= (int)(n); i++) #define MP make_pair using namespace std; typedef long long LL; typedef pair<int, int> PII; const LL INF = 0x3f3f3f3f3f3f3f; namespace flow { const int MAXN = 400; struct edge { int t...
replace
85
86
85
86
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int n, m, q, mod, fa[600010], id[50010][3][2], x = 0, g = 0, z; bool can_a[2][50010]; struct edge { int u, v, w; } e[50010]; int find(int a) { return fa[a] == a ? a : fa[a] = find(fa[a]); } int gcd(int x, int y) { return y ? gcd(y, x % y) : x; } void merge(int u, int v) {...
#include <bits/stdc++.h> using namespace std; int n, m, q, mod, fa[600010], id[50010][3][2], x = 0, g = 0, z; bool can_a[2][1000010]; struct edge { int u, v, w; } e[50010]; int find(int a) { return fa[a] == a ? a : fa[a] = find(fa[a]); } int gcd(int x, int y) { return y ? gcd(y, x % y) : x; } void merge(int u, int v)...
replace
3
4
3
4
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; const int Maxn = 50005; int gcd(int x, int y) { return y ? gcd(y, x % y) : x; } vector<tuple<int, int, int>> edge; int fa[6 * Maxn], chk[2][1000005]; int getid(int x, int p, int q) { return 6 * (x - 1) + 3 * p + q; } int Getfa(int x) { return fa[x] = (fa[x] == x ? x : Getfa...
#include <bits/stdc++.h> using namespace std; const int Maxn = 50005; int gcd(int x, int y) { return y ? gcd(y, x % y) : x; } vector<tuple<int, int, int>> edge; int fa[6 * Maxn], chk[2][1000005]; int getid(int x, int p, int q) { return 6 * (x - 1) + 3 * p + q; } int Getfa(int x) { return fa[x] = (fa[x] == x ? x : Getfa...
insert
22
22
22
24
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> #define mp make_pair #define mt make_tuple #define pb push_back #define fi first #define se second #define sz(a) int(a.size()) #define clr(a) memset(a, 0, sizeof(a)) #define all(a) a.begin(), a.end() using namespace std; typedef long long ll; typedef unsigned long long ull; typedef long double ...
#include <bits/stdc++.h> #define mp make_pair #define mt make_tuple #define pb push_back #define fi first #define se second #define sz(a) int(a.size()) #define clr(a) memset(a, 0, sizeof(a)) #define all(a) a.begin(), a.end() using namespace std; typedef long long ll; typedef unsigned long long ull; typedef long double ...
replace
103
104
103
104
0
p03100
C++
Runtime Error
#include <algorithm> #include <cmath> #include <cstdio> #include <iostream> using namespace std; const int Q = 1 << 19; int fa[Q]; int gf(int x) { return fa[x] == x ? x : (fa[x] = gf(fa[x])); } int X[Q], Y[Q], Z[Q]; int MOD; int id(int x, int y, int z) { return (x - 1) * 6 + y * 2 + z; } void Merge(int x, int y) { x ...
#include <algorithm> #include <cmath> #include <cstdio> #include <iostream> using namespace std; const int Q = 1 << 19; int fa[Q]; int gf(int x) { return fa[x] == x ? x : (fa[x] = gf(fa[x])); } int X[Q], Y[Q], Z[Q]; int MOD; int id(int x, int y, int z) { return (x - 1) * 6 + y * 2 + z; } void Merge(int x, int y) { x ...
replace
33
34
33
35
0
p03100
C++
Runtime Error
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstring> #include <iostream> #include <map> #include <queue> #include <set> #include <vector> #define N (500010) #define M () #define inf (0x7f7f7f7f) #define rg register int #define Label puts("NAIVE") #define spa print(' ') #define en...
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstring> #include <iostream> #include <map> #include <queue> #include <set> #include <vector> #define N (500010) #define M () #define inf (0x7f7f7f7f) #define rg register int #define Label puts("NAIVE") #define spa print(' ') #define en...
replace
101
103
101
103
-8
p03100
C++
Runtime Error
#include <stdio.h> int gcd(int a, int b) { if (b == 0) { return a; } return gcd(b, a % b); } int a[65536], b[65536], c[65536]; int fa1[1048576], fa2[1048576]; int findroot1(int x) { if (fa1[x] == x) { return x; } return fa1[x] = findroot1(fa1[x]); } int findroot2(int x) { if (fa2[x] == x) { re...
#include <stdio.h> int gcd(int a, int b) { if (a < 0) { a = -a; } if (b < 0) { b = -b; } if (b == 0) { return a; } return gcd(b, a % b); } int a[65536], b[65536], c[65536]; int fa1[1048576], fa2[1048576]; int findroot1(int x) { if (fa1[x] == x) { return x; } return fa1[x] = findroot1...
insert
2
2
2
8
0
p03100
C++
Runtime Error
#include <algorithm> #include <cstdio> using namespace std; int gi() { int x = 0, w = 1; char ch = getchar(); while ((ch < '0' || ch > '9') && ch != '-') ch = getchar(); if (ch == '-') w = 0, ch = getchar(); while (ch >= '0' && ch <= '9') x = (x << 3) + (x << 1) + ch - '0', ch = getchar(); retur...
#include <algorithm> #include <cstdio> using namespace std; int gi() { int x = 0, w = 1; char ch = getchar(); while ((ch < '0' || ch > '9') && ch != '-') ch = getchar(); if (ch == '-') w = 0, ch = getchar(); while (ch >= '0' && ch <= '9') x = (x << 3) + (x << 1) + ch - '0', ch = getchar(); retur...
replace
26
27
26
27
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> #define ll long long #define M 50010 using namespace std; template <typename T> void read(T &x) { x = 0; char c = getchar(); int fh = 1; while (!isdigit(c)) { if (c == '-') fh = -1; c = getchar(); } while (isdigit(c)) x = x * 10 + c - '0', c = getchar(); x *= fh;...
#include <bits/stdc++.h> #define ll long long #define M 50010 using namespace std; template <typename T> void read(T &x) { x = 0; char c = getchar(); int fh = 1; while (!isdigit(c)) { if (c == '-') fh = -1; c = getchar(); } while (isdigit(c)) x = x * 10 + c - '0', c = getchar(); x *= fh;...
replace
48
49
48
49
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> #pragma GCC optimize("O2,unroll-loops") // #pragma GCC optimize("no-stack-protector,fast-math") // #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") using namespace std; typedef long long ll; typedef long double ld; typedef pair<int, int> pii; typedef pair<pii, int>...
#include <bits/stdc++.h> #pragma GCC optimize("O2,unroll-loops") // #pragma GCC optimize("no-stack-protector,fast-math") // #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") using namespace std; typedef long long ll; typedef long double ld; typedef pair<int, int> pii; typedef pair<pii, int>...
insert
49
49
49
51
0
p03100
C++
Runtime Error
#include <algorithm> #include <cstdio> using namespace std; int n, m, Q, Mod, T, UF[301000], Z[50100]; struct point { int a, b, c; } w[101000]; int gcd(int a, int b) { return b ? gcd(b, a % b) : a; } int Find(int a) { if (a == UF[a]) return a; return UF[a] = Find(UF[a]); } void Merge(int a, int b) { a = Fin...
#include <algorithm> #include <cstdio> using namespace std; int n, m, Q, Mod, T, UF[6001000], Z[1000100]; struct point { int a, b, c; } w[101000]; int gcd(int a, int b) { return b ? gcd(b, a % b) : a; } int Find(int a) { if (a == UF[a]) return a; return UF[a] = Find(UF[a]); } void Merge(int a, int b) { a = ...
replace
3
4
3
4
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> #define fi first #define se second #define pb push_back #define SZ(x) ((int)x.size()) #define L(i, u) for (register int i = head[u]; i; i = nxt[i]) #define rep(i, a, b) for (register int i = (a); i <= (b); i++) #define per(i, a, b) for (register int i = (a); i >= (b); i--) using namespace std; ...
#include <bits/stdc++.h> #define fi first #define se second #define pb push_back #define SZ(x) ((int)x.size()) #define L(i, u) for (register int i = head[u]; i; i = nxt[i]) #define rep(i, a, b) for (register int i = (a); i <= (b); i++) #define per(i, a, b) for (register int i = (a); i >= (b); i--) using namespace std; ...
replace
56
57
56
57
0
p03100
C++
Runtime Error
#include <algorithm> #include <cstdio> #include <cstring> #define fo(i, a, b) for (int i = a; i <= b; i++) #define fd(i, a, b) for (int i = a; i >= b; i--) using namespace std; const int N = 1e6 + 5; int n, m, q, mod, s, t, r, u[N], v[N], c[N], g, fa[N]; bool can[2][N]; int Id(int x, int y, int z) { return (x - 1) *...
#include <algorithm> #include <cstdio> #include <cstring> #define fo(i, a, b) for (int i = a; i <= b; i++) #define fd(i, a, b) for (int i = a; i >= b; i--) using namespace std; const int N = 1e6 + 5; int n, m, q, mod, s, t, r, u[N], v[N], c[N], g, fa[N]; bool can[2][N]; int Id(int x, int y, int z) { return (x - 1) *...
replace
27
28
27
28
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int read() { int res = 0, w = 1; char c = getchar(); while (!isdigit(c) && c != '-') c = getchar(); if (c == '-') c = getchar(), w = -1; while (isdigit(c)) res = (res << 1) + (res << 3) + c - '0', c = getchar(); return res * w; } struct Dsu { ve...
#include <bits/stdc++.h> using namespace std; int read() { int res = 0, w = 1; char c = getchar(); while (!isdigit(c) && c != '-') c = getchar(); if (c == '-') c = getchar(), w = -1; while (isdigit(c)) res = (res << 1) + (res << 3) + c - '0', c = getchar(); return res * w; } struct Dsu { ve...
replace
65
66
65
66
0
p03100
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; const int MAXN = 3e5 + 5; const int MAXP = 1e6 + 5; typedef long long ll; template <typename T> void chkmax(T &x, T y) { x = max(x, y); } template <typename T> void chkmin(T &x, T y) { x = min(x, y); } template <typename T> void read(T &x) { x = 0; int f = 1; char c =...
#include <bits/stdc++.h> using namespace std; const int MAXN = 3e5 + 5; const int MAXP = 1e6 + 5; typedef long long ll; template <typename T> void chkmax(T &x, T y) { x = max(x, y); } template <typename T> void chkmin(T &x, T y) { x = min(x, y); } template <typename T> void read(T &x) { x = 0; int f = 1; char c =...
replace
35
36
35
36
0
p03101
Python
Runtime Error
H, W = int(input().split()) h, w = int(input().split()) print((H - h) * (W - w)) H, W = map(int, input().split()) h, w = map(int, input().split()) print((H - h) * (W - w))
H, W = map(int, input().split()) h, w = map(int, input().split()) print((H - h) * (W - w))
delete
0
4
0
0
TypeError: int() argument must be a string, a bytes-like object or a real number, not 'list'
Traceback (most recent call last): File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p03101/Python/s085592284.py", line 1, in <module> H, W = int(input().split()) TypeError: int() argument must be a string, a bytes-like object or a real number, not 'list'
p03101
Python
Runtime Error
"""A - White Cells https://atcoder.jp/contests/abc121/tasks/abc121_a >>> main([3, 2], [2, 1]) 1 >>> main([5, 5], [2, 3]) 6 >>> main([2, 4], [2, 4]) 0""" def main(amount, portion): print((amount[0] - portion[0]) * (amount[1] - portion[1])) if __name__ == "__main__": amount = map(int, input().split(" ")) ...
"""A - White Cells https://atcoder.jp/contests/abc121/tasks/abc121_a >>> main([3, 2], [2, 1]) 1 >>> main([5, 5], [2, 3]) 6 >>> main([2, 4], [2, 4]) 0""" def main(amount, portion): print((amount[0] - portion[0]) * (amount[1] - portion[1])) if __name__ == "__main__": amount = list(map(int, input().split(" ")...
replace
16
18
16
18
TypeError: 'map' object is not subscriptable
Traceback (most recent call last): File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p03101/Python/s794256981.py", line 20, in <module> main(amount, portion) File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p03101/Python/s794256981.py", line 13, in main print((amount[0] ...
p03101
C++
Time Limit Exceeded
/* author : s@if */ #include <bits/stdc++.h> using namespace std; #define NIL -1 #define fi first #define sec second #define MAX INT_MAX #define INF 99999999 #define ll long long #define PI acos(-1.0) #define MOD 1000000007 #define PLL pair<ll, ll> #define PII pair<int, int> #define triplell pair<pair<ll, ll>, l...
/* author : s@if */ #include <bits/stdc++.h> using namespace std; #define NIL -1 #define fi first #define sec second #define MAX INT_MAX #define INF 99999999 #define ll long long #define PI acos(-1.0) #define MOD 1000000007 #define PLL pair<ll, ll> #define PII pair<int, int> #define triplell pair<pair<ll, ll>, l...
replace
53
54
53
54
TLE
p03101
Python
Runtime Error
H, W, h, w = map(int, input().split()) print((H - h) * (W - w))
H, W = map(int, input().split()) h, w = map(int, input().split()) print((H - h) * (W - w))
replace
0
1
0
2
ValueError: not enough values to unpack (expected 4, got 2)
Traceback (most recent call last): File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p03101/Python/s695121527.py", line 1, in <module> H, W, h, w = map(int, input().split()) ValueError: not enough values to unpack (expected 4, got 2)
p03101
C++
Runtime Error
#include <iostream> using namespace std; int main() { int H, W, h, w; cin >> H; cin >> W; cin >> h; cin >> w; return (H - h) * (W - w); }
#include <iostream> using namespace std; int main() { int H, W, h, w; cin >> H; cin >> W; cin >> h; cin >> w; cout << (H - h) * (W - w); return 0; }
replace
11
12
11
13
1
p03101
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; int main() { int n, m; cin >> n >> m; vector<int> a(n), b(n); for (int i = 0; i < n; i++) { cin >> a[i] >> b[i]; } sort(a.begin(), a.end()); bool s = true; int cnt = 0, ans = 0; while (s) { for (int i = 0; i < 100000; i++) { if (cnt < m) { ...
#include <bits/stdc++.h> using namespace std; int main() { int H, W, h, w; cin >> H >> W >> h >> w; cout << (H - h) * (W - w) << endl; }
replace
4
26
4
8
TLE
p03101
C++
Runtime Error
#include <iostream> #include <vector> using namespace std; int main() { int H, W, h, w; cin >> H >> W; cin >> h >> w; int all = H * W; all = all - W * h - H * w + h * w; cout << all << endl; return all; }
#include <iostream> #include <vector> using namespace std; int main() { int H, W, h, w; cin >> H >> W; cin >> h >> w; int all = H * W; all = all - W * h - H * w + h * w; cout << all << endl; return 0; }
replace
13
14
13
14
1
p03101
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> ii; #define X first #define Y second #define PB push_back #define eps 1e-9 #define sz(x) (int)(x).size() #define all(x) (x).begin(), (x).end() #define rep(i, n) for (int i = 0; i < (int)(n); ++i) const int maxn = 1e6 + 7; inlin...
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int, int> ii; #define X first #define Y second #define PB push_back #define eps 1e-9 #define sz(x) (int)(x).size() #define all(x) (x).begin(), (x).end() #define rep(i, n) for (int i = 0; i < (int)(n); ++i) const int maxn = 1e6 + 7; inlin...
replace
31
35
31
35
0
p03101
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define FastRead \ ios::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0); #define ll long ...
#include <bits/stdc++.h> using namespace std; #define FastRead \ ios::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0); #define ll long ...
replace
38
42
38
42
0
p03101
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main(void) { //* int a, b, c, d; cin >> a >> b >> c >> d; //*/ /* vector<int> vec(3); cin >> vec.at(0) >> vec.at(1) >> vec.at(2) ; sort(vec.begin(), vec.end()); //*/ /* if( b / a < c ){ cout << b / a << endl; } else { cout << c <<...
#include <bits/stdc++.h> using namespace std; int main(void) { //* int a, b, c, d; cin >> a >> b >> c >> d; //*/ /* vector<int> vec(3); cin >> vec.at(0) >> vec.at(1) >> vec.at(2) ; sort(vec.begin(), vec.end()); //*/ /* if( b / a < c ){ cout << b / a << endl; } else { cout << c <<...
replace
24
25
24
25
0
p03101
C++
Runtime Error
#include <iostream> #include <vector> using namespace std; int main() { int H, W, h, w; cin >> H >> W; cin >> h >> w; int all = H * W; all = all - W * h - H * w + h * w; cout << all; return all; }
#include <iostream> #include <vector> using namespace std; int main() { int H, W, h, w; cin >> H >> W; cin >> h >> w; int all = H * W; all = all - W * h - H * w + h * w; cout << all << endl; return 0; }
replace
12
14
12
14
1
p03102
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; /*{{{*/ // template #define rep(i, n) for (int i = 0; i < (int)(n); i++) constexpr int INF = numeric_limits<int>::max() / 2; constexpr long long LINF = numeric_limits<long long>::max() / 3; #define mp make_pair #define pb push_back #define eb emplace_back #define fi first #...
#include <bits/stdc++.h> using namespace std; /*{{{*/ // template #define rep(i, n) for (int i = 0; i < (int)(n); i++) constexpr int INF = numeric_limits<int>::max() / 2; constexpr long long LINF = numeric_limits<long long>::max() / 3; #define mp make_pair #define pb push_back #define eb emplace_back #define fi first #...
replace
74
75
74
75
0
p03102
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; int main() { int n, m, c; cin >> n >> m >> c; vector<int> b(m); for (int i = 0; i < m; i++) { cin >> b.at(i); } vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < n; i++) { for (int j = 0; i < m; j++) { cin >> a[i][j]; } } int...
#include <bits/stdc++.h> using namespace std; int main() { int n, m, c; cin >> n >> m >> c; vector<int> b(m); for (int i = 0; i < m; i++) { cin >> b.at(i); } vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { cin >> a[i][j]; } } int...
replace
12
13
12
13
TLE
p03102
C++
Runtime Error
#include <iostream> #include <vector> using namespace std; int main() { int n, m, c; cin >> n >> m >> c; vector<int> b(1); for (int i = 0; i < m; i++) { cin >> b[i]; } vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { cin >> a[i][j]; ...
#include <iostream> #include <vector> using namespace std; int main() { int n, m, c; cin >> n >> m >> c; vector<int> b(m); for (int i = 0; i < m; i++) { cin >> b[i]; } vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < n; i++) { for (int j = 0; j < m; j++) { cin >> a[i][j]; ...
replace
8
9
8
9
0
p03102
C++
Runtime Error
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; using ll = long long; using ld = long double; using P = pair<int, int>; int main() { int n, m, c; cin >> n >> m >> c; vector<int> b(n); rep(i, m) cin >> b[i]; int ans = 0; rep(i, n) { int sum = 0; rep(j, ...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; using ll = long long; using ld = long double; using P = pair<int, int>; int main() { int n, m, c; cin >> n >> m >> c; vector<int> b(m); rep(i, m) cin >> b[i]; int ans = 0; rep(i, n) { int sum = 0; rep(j, ...
replace
10
11
10
11
0
p03102
C++
Runtime Error
#include <iostream> #include <numeric> #include <vector> using namespace std; int main() { int n, m, c, ans = 0; cin >> n >> m >> c; vector<int> b(m); vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < m; i++) cin >> b[i]; for (int i = 0; i < n; i++) for (int j = 0; j < m; j++) cin...
#include <iostream> #include <numeric> #include <vector> using namespace std; int main() { int n, m, c, ans = 0; cin >> n >> m >> c; vector<int> b(m); vector<vector<int>> a(n, vector<int>(m)); for (int i = 0; i < m; i++) cin >> b[i]; for (int i = 0; i < n; i++) for (int j = 0; j < m; j++) cin...
replace
16
19
16
18
-11
p03102
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int N, M, C; cin >> N >> M >> C; vector<int> B(M); int sum = 0; for (int i = 0; i < M; i++) { cin >> B.at(i); } int x = 0; for (int j = 0; j < N; j++) { int sum = 0; vector<int> S; for (int i = 0; i < M; i++) { cin ...
#include <bits/stdc++.h> using namespace std; int main() { int N, M, C; cin >> N >> M >> C; vector<int> B(M); int sum = 0; for (int i = 0; i < M; i++) { cin >> B.at(i); } int x = 0; for (int j = 0; j < N; j++) { int sum = 0; vector<int> S(M); for (int i = 0; i < M; i++) { c...
replace
19
20
19
20
-6
terminate called after throwing an instance of 'std::out_of_range' what(): vector::_M_range_check: __n (which is 0) >= this->size() (which is 0)
p03102
C++
Runtime Error
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); i++) using namespace std; typedef long long ll; int main() { int N, M; int C; cin >> N >> M >> C; vector<int> B(N); rep(i, M) cin >> B[i]; int ans = 0; rep(i, N) { ll S = 0; rep(j, M) { int A; cin >> A; S += A *...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); i++) using namespace std; typedef long long ll; int main() { int N, M; int C; cin >> N >> M >> C; vector<int> B(M); rep(i, M) cin >> B[i]; int ans = 0; rep(i, N) { ll S = 0; rep(j, M) { int A; cin >> A; S += A *...
replace
9
10
9
10
0
p03102
C++
Runtime Error
#include <iostream> #include <vector> using namespace std; using Int = long long; int main() { Int N, M, C, ans, count = 0; cin >> N >> M >> C; vector<Int> B(M); for (Int i = 0; i < M; i++) { cin >> B[i]; } vector<vector<int>> A(M); for (Int i = 0; i < N; i++) { A[i].resize(M); } for (Int i...
#include <iostream> #include <vector> using namespace std; using Int = long long; int main() { Int N, M, C, ans, count = 0; cin >> N >> M >> C; vector<Int> B(M); for (Int i = 0; i < M; i++) { cin >> B[i]; } vector<vector<int>> A(N); for (Int i = 0; i < N; i++) { A[i].resize(M); } for (Int i...
replace
14
15
14
15
0
p03102
C++
Runtime Error
#include <iostream> using namespace std; int main() { long long m, n, c, b[5], a, sum = 0, count = 0; cin >> n >> m >> c; for (int i = 0; i < m; i++) { cin >> b[i]; } for (int i = 0; i < n; i++) { sum = 0; for (int j = 0; j < m; j++) { cin >> a; sum += b[j] * a; } if (sum + c ...
#include <iostream> using namespace std; int main() { int m, n, c, b[100], a, sum = 0, count = 0; cin >> n >> m >> c; for (int i = 0; i < m; i++) { cin >> b[i]; } for (int i = 0; i < n; i++) { sum = 0; for (int j = 0; j < m; j++) { cin >> a; sum += b[j] * a; } if (sum + c > 0)...
replace
4
5
4
5
0
p03102
C++
Runtime Error
#include <iostream> #include <vector> using namespace std; int main(void) { int n, m, c, ans = 0; cin >> n >> m >> c; vector<int> b(n); for (int i = 0; i < m; i++) cin >> b[i]; for (int i = 0; i < n; i++) { int a, sum = 0; for (int j = 0; j < m; j++) cin >> a, sum += a * b[j]; ans += (...
#include <iostream> #include <vector> using namespace std; int main(void) { int n, m, c, ans = 0; cin >> n >> m >> c; vector<int> b(m); for (int i = 0; i < m; i++) cin >> b[i]; for (int i = 0; i < n; i++) { int a, sum = 0; for (int j = 0; j < m; j++) cin >> a, sum += a * b[j]; ans += (...
replace
8
9
8
9
0
p03102
C++
Runtime Error
#include <algorithm> #include <functional> #include <iostream> #include <map> #include <math.h> #include <numeric> #include <queue> #include <tuple> #include <vector> #define PI 3.14159265359 #define INF 100100100100100100 #define rep(i, n) for (int i = 0; i < n; i++) #define rep2(i, a, n) for (int i = a; i < n; i++) ...
#include <algorithm> #include <functional> #include <iostream> #include <map> #include <math.h> #include <numeric> #include <queue> #include <tuple> #include <vector> #define PI 3.14159265359 #define INF 100100100100100100 #define rep(i, n) for (int i = 0; i < n; i++) #define rep2(i, a, n) for (int i = a; i < n; i++) ...
replace
26
27
26
27
0
p03102
C++
Runtime Error
#include <bits/stdc++.h> #define ll long long using namespace std; int main() { int n, m, c; cin >> n >> m >> c; vector<int> v(n); for (int i = 0; i < m; i++) cin >> v[i]; int res = 0; for (int i = 0; i < n; i++) { int sum = 0; for (int j = 0; j < m; j++) { int a; cin >> a; su...
#include <bits/stdc++.h> #define ll long long using namespace std; int main() { int n, m, c; cin >> n >> m >> c; vector<int> v(m); for (int i = 0; i < m; i++) cin >> v[i]; int res = 0; for (int i = 0; i < n; i++) { int sum = 0; for (int j = 0; j < m; j++) { int a; cin >> a; su...
replace
7
8
7
8
0
p03102
C++
Runtime Error
#include <bits/stdc++.h> #define MOD (long long)(1E9 + 7) #define rep(i, n) for (int i = 0; i < n; i++) using namespace std; int main() { int n, m, c, cnt = 0; cin >> n >> m >> c; vector<int> b(n); rep(i, m) { cin >> b[i]; } rep(i, n) { int a, t = 0; rep(j, m) { cin >> a; t += a * b[j]; ...
#include <bits/stdc++.h> #define MOD (long long)(1E9 + 7) #define rep(i, n) for (int i = 0; i < n; i++) using namespace std; int main() { int n, m, c, cnt = 0; cin >> n >> m >> c; vector<int> b(m); rep(i, m) { cin >> b[i]; } rep(i, n) { int a, t = 0; rep(j, m) { cin >> a; t += a * b[j]; ...
replace
9
10
9
10
0
p03102
C++
Runtime Error
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstring> #include <deque> #include <forward_list> #include <functional> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <utility> #include <vector> #define ll long long int...
#include <algorithm> #include <bitset> #include <cmath> #include <cstdio> #include <cstring> #include <deque> #include <forward_list> #include <functional> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <utility> #include <vector> #define ll long long int...
replace
28
29
28
29
0