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
p03264
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define DEBUG(x) cout << '>' << #x << ':' << x << endl; #define D(x) cerr << __LINE__ << ": " << #x << " = " << (x) << '\n' #define DD(x, y) \ cerr << __LINE__ << ": " << #x << " = " << x << " " << #y << " = " << y \ << '\n' #define DDD(x, y, z) \ cerr << __LINE__ << ": " << #x << " = " << x << " " << #y << " = " << y \ << " " << #z << " = " << z << '\n' #define DBG cerr << __LINE__ << ": Hi" << '\n' #define fresh \ { \ ios_base::sync_with_stdio(false); \ cin.tie(NULL); \ cout.tie(NULL); \ } #define read freopen("in.txt", "rt", stdin) #define write freopen("out.txt", "wt", stdout) #define PI 3.1415926535897932384626433832795 #define mems(ds_name, val) memset(ds_name, val, sizeof(ds_name)) int main() { fresh; read; // write; int t; cin >> t; int divs = t / 2; int mods = t % 2; if (!mods) { cout << divs * divs << endl; } else { cout << divs * (divs + 1) << endl; } }
#include <bits/stdc++.h> using namespace std; #define DEBUG(x) cout << '>' << #x << ':' << x << endl; #define D(x) cerr << __LINE__ << ": " << #x << " = " << (x) << '\n' #define DD(x, y) \ cerr << __LINE__ << ": " << #x << " = " << x << " " << #y << " = " << y \ << '\n' #define DDD(x, y, z) \ cerr << __LINE__ << ": " << #x << " = " << x << " " << #y << " = " << y \ << " " << #z << " = " << z << '\n' #define DBG cerr << __LINE__ << ": Hi" << '\n' #define fresh \ { \ ios_base::sync_with_stdio(false); \ cin.tie(NULL); \ cout.tie(NULL); \ } #define read freopen("in.txt", "rt", stdin) #define write freopen("out.txt", "wt", stdout) #define PI 3.1415926535897932384626433832795 #define mems(ds_name, val) memset(ds_name, val, sizeof(ds_name)) int main() { fresh; #ifndef ONLINE_JUDGE // read; #endif // write; int t; cin >> t; int divs = t / 2; int mods = t % 2; if (!mods) { cout << divs * divs << endl; } else { cout << divs * (divs + 1) << endl; } }
replace
25
26
25
28
0
p03264
C++
Runtime Error
#include <stdio.h> int main() { int k; scanf("%d", k); if (k % 2 == 0) { printf("%d", k / 2 * k / 2); } if (k % 2 == 1) { printf("%d", k / 2 * (k + 1) / 2); } return 0; }
#include <stdio.h> int main() { int k; scanf("%d", &k); if (k % 2 == 0) { printf("%d", k / 2 * k / 2); } if (k % 2 == 1) { printf("%d", k / 2 * (k + 1) / 2); } return 0; }
replace
3
4
3
4
-11
p03264
C++
Time Limit Exceeded
#define taskname "data" #include <bits/stdc++.h> #define FOR(i, a, b) for (int i = (a); i <= (b); ++i) #define FOD(i, a, b) for (int i = (a); i >= (b); --i) #define RP(i, a, b) for (int i = (a); i < (b); ++i) #define FORE(i, a) \ for (__typeof((a).begin()) i = (a).begin(); i != (a).end(); ++i) #define FRSZ(i, a) for (int i = 0; i < (a).size(); ++i) #define FPSZ(i, a) for (int i = 0; i < (a).size() - 1; ++i) #define RPSZ(i, a) for (int i = 1; i < (a).size(); ++i) #define FDSZ(i, a) for (int i = (a).size() - 1; i >= 0; --i) #define ALL(x) (x).begin(), (x).end() #define Bit(x, y) (((x) >> ((y)-1)) & 1) #define NumBit(x) (__builtin_popcount(x)) #define __unique(a) \ sort((a).begin(), (a).end()), a.resize(unique(a.begin(), a.end()) - a.begin()) #define SET(x) memset(x, -1, sizeof x) #define CLR(x) memset(x, 0, sizeof x) #define BIG(x) memset(x, 0x3f3f3f3f, sizeof x); #define debugarr(a, n) \ { \ FOR(_, 1, n) printf("%d ", (a)[_]); \ cout << endl; \ } #define debugvi(x) \ { \ FRSZ(_, x) cout << (x)[_] << " "; \ cout << endl; \ } #define debug(x) cout << #x << " = " << (x) << endl; #define fi first #define se second using namespace std; template <typename T> void Read(T &x) { char ch; bool neg = 0; x = 0; while (!isdigit(ch = getchar()) && ch != '-') ; if (ch == '-') { neg = 1; ch = getchar(); } do { x = x * 10 + ch - 48; } while (isdigit(ch = getchar())); if (neg) x = -x; return; } template <typename T> void Write(T x) { char ch[32]; int cnt = 0; bool neg = 0; if (x < 0) { neg = 1; x = -x; } do { ch[++cnt] = x % 10 + 48; x /= 10; } while (x); if (neg) putchar('-'); FOD(i, cnt, 1) putchar(ch[i]); } template <typename T> void Writenm(T x, int num) { char ch[32]; int cnt = 0, cntDigit = 0; ; bool neg = 0; if (x < 0) { neg = 1; x = -x; } do { ch[++cnt] = x % 10 + 48; x /= 10; ++cntDigit; } while (x); if (neg) putchar('-'); FOR(i, cntDigit + 1, num) putchar('0'); FOD(i, cnt, 1) putchar(ch[i]); } template <typename T> void Writeln(T x) { Write(x); putchar('\n'); } template <typename T> void Writesp(T x) { Write(x); putchar(' '); } int n; void Enter() { Read(n); } void Solve() { if (n % 2) Write((n / 2) * (n / 2 + 1)); else Write((n / 2) * (n / 2)); } int main(int argc, char const *argv[]) { #ifndef ONLINE_JUDGE freopen(taskname ".inp", "r", stdin); freopen(taskname ".out", "w", stdout); #endif Enter(); Solve(); return 0; }
#define taskname "data" #include <bits/stdc++.h> #define FOR(i, a, b) for (int i = (a); i <= (b); ++i) #define FOD(i, a, b) for (int i = (a); i >= (b); --i) #define RP(i, a, b) for (int i = (a); i < (b); ++i) #define FORE(i, a) \ for (__typeof((a).begin()) i = (a).begin(); i != (a).end(); ++i) #define FRSZ(i, a) for (int i = 0; i < (a).size(); ++i) #define FPSZ(i, a) for (int i = 0; i < (a).size() - 1; ++i) #define RPSZ(i, a) for (int i = 1; i < (a).size(); ++i) #define FDSZ(i, a) for (int i = (a).size() - 1; i >= 0; --i) #define ALL(x) (x).begin(), (x).end() #define Bit(x, y) (((x) >> ((y)-1)) & 1) #define NumBit(x) (__builtin_popcount(x)) #define __unique(a) \ sort((a).begin(), (a).end()), a.resize(unique(a.begin(), a.end()) - a.begin()) #define SET(x) memset(x, -1, sizeof x) #define CLR(x) memset(x, 0, sizeof x) #define BIG(x) memset(x, 0x3f3f3f3f, sizeof x); #define debugarr(a, n) \ { \ FOR(_, 1, n) printf("%d ", (a)[_]); \ cout << endl; \ } #define debugvi(x) \ { \ FRSZ(_, x) cout << (x)[_] << " "; \ cout << endl; \ } #define debug(x) cout << #x << " = " << (x) << endl; #define fi first #define se second using namespace std; template <typename T> void Read(T &x) { char ch; bool neg = 0; x = 0; while (!isdigit(ch = getchar()) && ch != '-') ; if (ch == '-') { neg = 1; ch = getchar(); } do { x = x * 10 + ch - 48; } while (isdigit(ch = getchar())); if (neg) x = -x; return; } template <typename T> void Write(T x) { char ch[32]; int cnt = 0; bool neg = 0; if (x < 0) { neg = 1; x = -x; } do { ch[++cnt] = x % 10 + 48; x /= 10; } while (x); if (neg) putchar('-'); FOD(i, cnt, 1) putchar(ch[i]); } template <typename T> void Writenm(T x, int num) { char ch[32]; int cnt = 0, cntDigit = 0; ; bool neg = 0; if (x < 0) { neg = 1; x = -x; } do { ch[++cnt] = x % 10 + 48; x /= 10; ++cntDigit; } while (x); if (neg) putchar('-'); FOR(i, cntDigit + 1, num) putchar('0'); FOD(i, cnt, 1) putchar(ch[i]); } template <typename T> void Writeln(T x) { Write(x); putchar('\n'); } template <typename T> void Writesp(T x) { Write(x); putchar(' '); } int n; void Enter() { Read(n); } void Solve() { if (n % 2) Write((n / 2) * (n / 2 + 1)); else Write((n / 2) * (n / 2)); } int main(int argc, char const *argv[]) { Enter(); Solve(); return 0; }
delete
113
118
113
113
TLE
p03264
C++
Time Limit Exceeded
#include <iostream> using namespace std; int main() { int k; cin >> k; int even = k / 2; int odd = k / 2 + k % 2; cout << even * odd << endl; while (1) ; return 0; }
#include <iostream> using namespace std; int main() { int k; cin >> k; int even = k / 2; int odd = k / 2 + k % 2; cout << even * odd << endl; return 0; }
delete
11
13
11
11
TLE
p03264
C++
Time Limit Exceeded
#include <iostream> using namespace std; int main() { int N; cin >> N; int count = 0; for (int i = 1; i <= N; i++) { for (int j = i; j <= N; i++) { if (i == j) continue; if (i % 2 == 0 && j % 2 == 1) count++; else if (j % 2 == 0 && i % 2 == 1) count++; } } cout << count; }
#include <iostream> using namespace std; int main() { int N; cin >> N; int count = 0; for (int i = 1; i <= N; i++) { for (int j = i; j <= N; j++) { if (i == j) continue; if (i % 2 == 0 && j % 2 == 1) count++; else if (j % 2 == 0 && i % 2 == 1) count++; } } cout << count; }
replace
9
10
9
10
TLE