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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
p02634 | C++ | Time Limit Exceeded | #include <algorithm>
#include <bitset>
#include <cassert>
#include <climits>
#include <cmath>
#include <cstdlib>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <string>
#include <vector>
#define DEBUG 1
using namespace std;
constexpr int kMod = 998244353;
typedef long lon... | #include <algorithm>
#include <bitset>
#include <cassert>
#include <climits>
#include <cmath>
#include <cstdlib>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <string>
#include <vector>
#define DEBUG 1
using namespace std;
constexpr int kMod = 998244353;
typedef long lon... | replace | 28 | 38 | 28 | 33 | TLE | |
p02634 | C++ | Runtime Error | #include <bits/stdc++.h>
/* Uncomment only if you are not using GNU compiler->
*/
#include <algorithm>
#include <chrono>
#include <iomanip>
#include <map>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <thread>
#include <vector>
/**/
// define
#define rep(i, n) for (int i = 0; i ... | #include <bits/stdc++.h>
/* Uncomment only if you are not using GNU compiler->
*/
#include <algorithm>
#include <chrono>
#include <iomanip>
#include <map>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <thread>
#include <vector>
/**/
// define
#define rep(i, n) for (int i = 0; i ... | replace | 106 | 109 | 106 | 107 | -11 | |
p02634 | C++ | Runtime Error | #include <bits/stdc++.h>
#define int long long
using namespace std;
const int inf = 1e9 + 7;
const int N = 3 * 1e3 + 1;
const int MOD = 998244353;
int dp[N][N];
signed main() {
ios_base::sync_with_stdio(NULL);
cin.tie(0);
cout.tie(0);
int a, b, c, d;
cin >> a >> b >> c >> d;
dp[a][b] = 1;
for (int i = a; ... | #include <bits/stdc++.h>
#define int long long
using namespace std;
const int inf = 1e9 + 7;
const int N = 3 * 1e3 + 111;
const int MOD = 998244353;
int dp[N][N];
signed main() {
ios_base::sync_with_stdio(NULL);
cin.tie(0);
cout.tie(0);
int a, b, c, d;
cin >> a >> b >> c >> d;
dp[a][b] = 1;
for (int i = a... | replace | 4 | 5 | 4 | 5 | 0 | |
p02634 | C++ | Time Limit Exceeded | #include <algorithm>
#include <iostream>
using namespace std;
const long long mod = 998244353;
int main(void) {
long long A, B, C, D;
cin >> A >> B >> C >> D;
long long DP[3001][3001];
DP[A][B] = 1;
long long ans = 0;
long long N;
long long i, j, t, k;
for (i = A + 1; i < C + 1; i++) {
DP[i][B] = D... | #include <algorithm>
#include <iostream>
using namespace std;
const long long mod = 998244353;
int main(void) {
long long A, B, C, D;
cin >> A >> B >> C >> D;
long long DP[3001][3001];
DP[A][B] = 1;
long long ans = 0;
long long N;
long long i, j, t, k;
for (i = A + 1; i < C + 1; i++) {
DP[i][B] = D... | replace | 27 | 28 | 27 | 28 | TLE | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
#define long long long int
using namespace std;
// @author: pashka
int mod = 998244353;
struct mint {
int value;
constexpr mint() : value() {}
mint(const long &x) { value = normalize(x); }
static long normalize(const long &x) {
long v = x % mod;
if (v < 0)
v += mod;
... | #include <bits/stdc++.h>
#define long long long int
using namespace std;
// @author: pashka
int mod = 998244353;
struct mint {
int value;
constexpr mint() : value() {}
mint(const long &x) { value = normalize(x); }
static long normalize(const long &x) {
long v = x % mod;
if (v < 0)
v += mod;
... | insert | 34 | 34 | 34 | 35 | -11 | |
p02635 | C++ | Runtime Error | // #pragma GCC target("avx,avx2,fma")
// #pragma GCC optimization ("Ofast")
// #pragma GCC optimization ("unroll-loops")
#include <bits/stdc++.h>
using namespace std;
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// using namespace __gnu_pbds;
// template <typename T>
// using o_s... | // #pragma GCC target("avx,avx2,fma")
// #pragma GCC optimization ("Ofast")
// #pragma GCC optimization ("unroll-loops")
#include <bits/stdc++.h>
using namespace std;
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// using namespace __gnu_pbds;
// template <typename T>
// using o_s... | insert | 71 | 71 | 71 | 75 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define REP(i, m, n) for (int i = (int)(m); i < (int)(n); i++)
#define rep(i, n) REP(i, 0, n)
#define RREP(i, m, n) for (int i = (int)(m); i >= (int)(n); i--)
#define rrep(i, n) RREP(i, n - 1, 0)
#define all(v) v.begin(), v.end()
const int inf = 1e9 + 7... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define REP(i, m, n) for (int i = (int)(m); i < (int)(n); i++)
#define rep(i, n) REP(i, 0, n)
#define RREP(i, m, n) for (int i = (int)(m); i >= (int)(n); i--)
#define rrep(i, n) RREP(i, n - 1, 0)
#define all(v) v.begin(), v.end()
const int inf = 1e9 + 7... | replace | 58 | 59 | 58 | 59 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
typedef long long lol;
const int mod = 998244353;
inline int pls(int a, int b) {
a += b - mod;
return a + (a >> 31 & mod);
}
inline int mns(int a, int b) {
a -= b;
return a + (a >> 31 & mod);
}
inline void inc(int &a, int b) {
a += b - mod;
a += a >> 31 & mod;... | #include <bits/stdc++.h>
using namespace std;
typedef long long lol;
const int mod = 998244353;
inline int pls(int a, int b) {
a += b - mod;
return a + (a >> 31 & mod);
}
inline int mns(int a, int b) {
a -= b;
return a + (a >> 31 & mod);
}
inline void inc(int &a, int b) {
a += b - mod;
a += a >> 31 & mod;... | insert | 51 | 51 | 51 | 52 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
#define For(i, a, b) for (int(i) = (int)(a); (i) < (int)(b); ++(i))
#define rFor(i, a, b) for (int(i) = (int)(a)-1; (i) >= (int)(b); --(i))
#define rep(i, n) For((i), 0, (n))
#define rrep(i, n) rFor((i), (n), 0)
#define fi first
#define se second
using namespace std;
typedef long long lint;
typ... | #include <bits/stdc++.h>
#define For(i, a, b) for (int(i) = (int)(a); (i) < (int)(b); ++(i))
#define rFor(i, a, b) for (int(i) = (int)(a)-1; (i) >= (int)(b); --(i))
#define rep(i, n) For((i), 0, (n))
#define rrep(i, n) rFor((i), (n), 0)
#define fi first
#define se second
using namespace std;
typedef long long lint;
typ... | replace | 165 | 166 | 165 | 166 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
string S;
ll N;
ll K;
vector<ll> A;
ll M;
vector<vector<vector<ll>>> Dp;
const ll MOD = 998244353;
ll Res;
int main() {
cin >> S >> K;
N = S.size();
reverse(S.begin(), S.end());
ll now = 0;
for (char c : S) {
if (c == '0') {
A.pu... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
string S;
ll N;
ll K;
vector<ll> A;
ll M;
vector<vector<vector<ll>>> Dp;
const ll MOD = 998244353;
ll Res;
int main() {
cin >> S >> K;
N = S.size();
K = min(N, K);
reverse(S.begin(), S.end());
ll now = 0;
for (char c : S) {
if (c == ... | insert | 17 | 17 | 17 | 18 | 0 | |
p02635 | C++ | Runtime Error | #include <algorithm>
#include <iostream>
#include <string>
#include <vector>
#define rep(i, n) for (i = 0; i < n; i++)
using namespace std;
void reverse(string &s) {
int l = 0, r = s.length() - 1;
while (l < r) {
swap(s[l], s[r]);
l++;
r--;
}
}
int mod = 998244353;
string s;
int K;
vector<int> a;
ve... | #include <algorithm>
#include <iostream>
#include <string>
#include <vector>
#define rep(i, n) for (i = 0; i < n; i++)
using namespace std;
void reverse(string &s) {
int l = 0, r = s.length() - 1;
while (l < r) {
swap(s[l], s[r]);
l++;
r--;
}
}
int mod = 998244353;
string s;
int K;
vector<int> a;
ve... | insert | 28 | 28 | 28 | 29 | -11 | |
p02635 | C++ | Runtime Error | #include <cstdio>
#include <cstring>
const long long mod = 998244353;
char s[400];
long long f[400][400][400];
int count[400], sum[400];
long long preSum[400][400];
const int offset = 310;
long long diaSum[800][400];
int max(int a, int b) { return a > b ? a : b; }
void preWork(int p, int n, int m) {
for (int i = 0;... | #include <cstdio>
#include <cstring>
const long long mod = 998244353;
char s[400];
long long f[400][400][400];
int count[400], sum[400];
long long preSum[400][400];
const int offset = 310;
long long diaSum[800][400];
int max(int a, int b) { return a > b ? a : b; }
void preWork(int p, int n, int m) {
for (int i = 0;... | insert | 78 | 78 | 78 | 79 | -11 | |
p02635 | C++ | Runtime Error | /**
* code generated by JHelper
* More info: https://github.com/AlexeyDmitriev/JHelper
* @author majk
*/
#ifndef MAJK_LIB
#define MAJK_LIB
#include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <cmath>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#in... | /**
* code generated by JHelper
* More info: https://github.com/AlexeyDmitriev/JHelper
* @author majk
*/
#ifndef MAJK_LIB
#define MAJK_LIB
#include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <cmath>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#in... | insert | 328 | 328 | 328 | 329 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
template <int MOD_> struct modnum {
static constexpr int MOD = MOD_;
static_assert(MOD_ > 0, "MOD must be positive");
private:
using ll = long long;
int v;
static int minv(int a, int m) {
a %= m;
assert(a);
return a == 1 ? 1 : int(m - ll(minv(m, a)... | #include <bits/stdc++.h>
using namespace std;
template <int MOD_> struct modnum {
static constexpr int MOD = MOD_;
static_assert(MOD_ > 0, "MOD must be positive");
private:
using ll = long long;
int v;
static int minv(int a, int m) {
a %= m;
assert(a);
return a == 1 ? 1 : int(m - ll(minv(m, a)... | insert | 166 | 166 | 166 | 167 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define int long long
const int MAX = 510000;
const int MOD = 998244353;
signed main() {
string s;
int K;
cin >> s >> K;
vector<int> c;
c.push_back(0);
int t = 0;
for (auto &&i : s) {
if (i == '0')
c.push_back(0);
else {
c[c.size() - 1]++;... | #include <bits/stdc++.h>
using namespace std;
#define int long long
const int MAX = 510000;
const int MOD = 998244353;
signed main() {
string s;
int K;
cin >> s >> K;
vector<int> c;
c.push_back(0);
int t = 0;
for (auto &&i : s) {
if (i == '0')
c.push_back(0);
else {
c[c.size() - 1]++;... | replace | 39 | 40 | 39 | 40 | 0 | |
p02635 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
const int maxn = 300 + 10;
typedef long long ll;
const ll mod = 998244353;
int tot, K;
char s[maxn];
int a[maxn];
ll f[maxn][maxn][maxn];
ll ans;
inline ll norm(const ll &x) { return x >= mod ? x - mod : x; }
int main() {
scanf("%s%d", s + 1, &K);
int len = strlen(s + 1... | #include <bits/stdc++.h>
using namespace std;
const int maxn = 300 + 10;
typedef long long ll;
const ll mod = 998244353;
int tot, K;
char s[maxn];
int a[maxn];
ll f[maxn][maxn][maxn];
ll ans;
inline ll norm(const ll &x) { return x >= mod ? x - mod : x; }
int main() {
scanf("%s%d", s + 1, &K);
K = min(K, 300);
int... | insert | 13 | 13 | 13 | 14 | TLE | |
p02635 | C++ | Runtime Error | /**
* code generated by JHelper
* More info: https://github.com/AlexeyDmitriev/JHelper
* @author Ido Kessler
*/
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cstdint>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <qu... | /**
* code generated by JHelper
* More info: https://github.com/AlexeyDmitriev/JHelper
* @author Ido Kessler
*/
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cstdint>
#include <fstream>
#include <functional>
#include <iomanip>
#include <iostream>
#include <map>
#include <numeric>
#include <qu... | replace | 434 | 435 | 434 | 435 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { ce... | #include <bits/stdc++.h>
using namespace std;
void __print(int x) { cerr << x; }
void __print(long x) { cerr << x; }
void __print(long long x) { cerr << x; }
void __print(unsigned x) { cerr << x; }
void __print(unsigned long x) { cerr << x; }
void __print(unsigned long long x) { cerr << x; }
void __print(float x) { ce... | insert | 76 | 76 | 76 | 77 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i <= (b); ++i)
#define rrep(i, a, b) for (int i = (a); i >= (b); --i)
#define PB push_back
#define ar2 array<int, 2>
#define vs vector<string>
typedef long long LL;
const int P = 998244353;
const int N = 305;
mt19937 rng(time(0));
int... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i <= (b); ++i)
#define rrep(i, a, b) for (int i = (a); i >= (b); --i)
#define PB push_back
#define ar2 array<int, 2>
#define vs vector<string>
typedef long long LL;
const int P = 998244353;
const int N = 305;
mt19937 rng(time(0));
int... | insert | 40 | 40 | 40 | 42 | -11 | |
p02635 | C++ | Runtime Error | /*input
01100110 2
*/
#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;
#pragma GCC optimize("unroll-loops,no-stack-protector")
// order_of_key #of elements less than x
// find_by_order kth element
#define ll long lo... | /*input
01100110 2
*/
#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;
#pragma GCC optimize("unroll-loops,no-stack-protector")
// order_of_key #of elements less than x
// find_by_order kth element
#define ll long lo... | replace | 52 | 53 | 52 | 53 | 0 | |
p02635 | C++ | Runtime Error | #include <bitset>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <vector>
using namespace std;
typedef long long ll;
const int N = 310, mod = 998244353;
char s[N];
int K, ct, n, m;
int w[N];
ll sum, f[N][N][N];
void pls(ll &x, ll y) {
x += y;
x >= ... | #include <bitset>
#include <cmath>
#include <cstdio>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <vector>
using namespace std;
typedef long long ll;
const int N = 310, mod = 998244353;
char s[N];
int K, ct, n, m;
int w[N];
ll sum, f[N][N][N];
void pls(ll &x, ll y) {
x += y;
x >= ... | insert | 43 | 43 | 43 | 44 | -11 | |
p02635 | C++ | Runtime Error | #include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <climits>
#include <cmath>
#include <complex>
#include <cstring>
#include <functional>
#include <iomanip>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include ... | #include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <climits>
#include <cmath>
#include <complex>
#include <cstring>
#include <functional>
#include <iomanip>
#include <iostream>
#include <limits>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include ... | replace | 507 | 508 | 507 | 508 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
#define ll long long
using namespace std;
const int p = 998244353;
int n, m, mx, i, j, k, l, val, ans, f[302][302][302], a[302], b[302], sum, sz;
char s[10010];
int main() {
scanf("%s", s + 1);
scanf("%d", &mx);
n = strlen(s + 1);
for (i = 1; i <= n; i++) {
if (s[i] == '1')
sz... | #include <bits/stdc++.h>
#define ll long long
using namespace std;
const int p = 998244353;
int n, m, mx, i, j, k, l, val, ans, f[302][302][302], a[302], b[302], sum, sz;
char s[10010];
int main() {
scanf("%s", s + 1);
scanf("%d", &mx);
n = strlen(s + 1);
for (i = 1; i <= n; i++) {
if (s[i] == '1')
sz... | replace | 32 | 33 | 32 | 33 | -11 | |
p02635 | C++ | Runtime Error | #include <algorithm>
#include <bitset>
#include <cassert>
#include <chrono>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstring>
#include <deque>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#inclu... | #include <algorithm>
#include <bitset>
#include <cassert>
#include <chrono>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdint>
#include <cstring>
#include <deque>
#include <functional>
#include <iomanip>
#include <iostream>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#inclu... | replace | 208 | 209 | 208 | 209 | 0 | |
p02635 | C++ | Runtime Error | #include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
using namespace std;
#define MOD 998244353
#define ADD(X, Y) ((X) = ((X) + (Y) % MOD) % MOD)
typedef long long i64;
typedef... | #include <algorithm>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
using namespace std;
#define MOD 998244353
#define ADD(X, Y) ((X) = ((X) + (Y) % MOD) % MOD)
typedef long long i64;
typedef... | insert | 66 | 66 | 66 | 68 | 0 | |
p02635 | C++ | Runtime Error | #ifdef _MSC_VER
#define _CRT_SECURE_NO_WARNINGS
#include <intrin.h>
#define __builtin_popcount __popcnt
#endif
#define _USE_MATH_DEFINES
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cinttypes>
#include <cmath>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#inc... | #ifdef _MSC_VER
#define _CRT_SECURE_NO_WARNINGS
#include <intrin.h>
#define __builtin_popcount __popcnt
#endif
#define _USE_MATH_DEFINES
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cinttypes>
#include <cmath>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#inc... | replace | 245 | 246 | 245 | 247 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i < (b); ++i)
#define per(i, a, b) for (int i = (b)-1; i >= (a); --i)
#define all(x) begin(x), end(x)
#define sz(x) (int)(x).size()
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define fst first
#define snd second... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i < (b); ++i)
#define per(i, a, b) for (int i = (b)-1; i >= (a); --i)
#define all(x) begin(x), end(x)
#define sz(x) (int)(x).size()
#define pb push_back
#define eb emplace_back
#define mp make_pair
#define fst first
#define snd second... | insert | 39 | 39 | 39 | 40 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const ll MOD = 998244353;
ll po[302][302];
ll C[602][602];
void init() {
for (int i = 0; i < 302; i++) {
po[i][0] = 1;
for (int j = 0; j + 1 < 302; j++) {
po[i][j + 1] = po[i][j] * i;
po[i][j + 1] %= MOD;
}
}
for (int i ... | #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const ll MOD = 998244353;
ll po[302][302];
ll C[602][602];
void init() {
for (int i = 0; i < 302; i++) {
po[i][0] = 1;
for (int j = 0; j + 1 < 302; j++) {
po[i][j + 1] = po[i][j] * i;
po[i][j + 1] %= MOD;
}
}
for (int i ... | replace | 105 | 106 | 105 | 106 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#ifdef NeverBeRed
#include "debug.h"
#else
#define debug(...) 9715
#endif
typedef long long ll;
typedef long double ld;
typedef complex<ld> point;
#define F first
#define S second
const int mod = 998244353;
int dp[305][305][305];
int dp2[305][305][305];
int dp3[305][305]... | #include <bits/stdc++.h>
using namespace std;
#ifdef NeverBeRed
#include "debug.h"
#else
#define debug(...) 9715
#endif
typedef long long ll;
typedef long double ld;
typedef complex<ld> point;
#define F first
#define S second
const int mod = 998244353;
int dp[305][305][305];
int dp2[305][305][305];
int dp3[305][305]... | replace | 78 | 79 | 78 | 79 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
#define all(vec) vec.begin(), vec.end()
#define pb push_back
#define eb emplace_back
#define fi first
#define se second
using namespace std;
using ll = long long;
using P = pair<ll, ll>;
template <class T> using V = vector<T>;
template <class T> inline void chmin(T &a, const T &b) { a = min(a, ... | #include <bits/stdc++.h>
#define all(vec) vec.begin(), vec.end()
#define pb push_back
#define eb emplace_back
#define fi first
#define se second
using namespace std;
using ll = long long;
using P = pair<ll, ll>;
template <class T> using V = vector<T>;
template <class T> inline void chmin(T &a, const T &b) { a = min(a, ... | replace | 158 | 159 | 158 | 159 | 0 | |
p02635 | C++ | Runtime Error | #include <algorithm>
#include <cstdio>
#include <cstring>
#define For(i, a, b) for (register int i = a; i <= b; ++i)
using namespace std;
const int maxn = 3e2 + 5;
const int mod = 998244353;
int f[maxn][maxn][maxn], K, N, n, num[maxn], ans;
// x k owe
char s[maxn];
void Add(int &x, const int &a) { x = (x + a) >... | #include <algorithm>
#include <cstdio>
#include <cstring>
#define For(i, a, b) for (register int i = a; i <= b; ++i)
using namespace std;
const int maxn = 3e2 + 5;
const int mod = 998244353;
int f[maxn][maxn][maxn], K, N, n, num[maxn], ans;
// x k owe
char s[maxn];
void Add(int &x, const int &a) { x = (x + a) >... | insert | 22 | 22 | 22 | 23 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
using lint = long long;
constexpr lint mod = 998244353;
#define all(x) (x).begin(), (x).end()
#define bitcount(n) __builtin_popcountl((lint)(n))
#define fcout cout << fixed << setprecision(15)
#define highest(x) (63 - __builtin_clzl(x))
#define rep(i, n) for (int i = 0; i <... | #include <bits/stdc++.h>
using namespace std;
using lint = long long;
constexpr lint mod = 998244353;
#define all(x) (x).begin(), (x).end()
#define bitcount(n) __builtin_popcountl((lint)(n))
#define fcout cout << fixed << setprecision(15)
#define highest(x) (63 - __builtin_clzl(x))
#define rep(i, n) for (int i = 0; i <... | insert | 167 | 167 | 167 | 168 | 0 | |
p02635 | C++ | Runtime Error | // #define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
#define all(v) v.begin(), v.end()
#define rall(v) v.rbegin(), v.rend()
using namespace std;
using ll = int64_t;
using ld = long double;
using P = pair<int, int>;
using vs = vector<string>;
using vi = vector<int>;
using vvi ... | // #define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < n; ++i)
#define all(v) v.begin(), v.end()
#define rall(v) v.rbegin(), v.rend()
using namespace std;
using ll = int64_t;
using ld = long double;
using P = pair<int, int>;
using vs = vector<string>;
using vi = vector<int>;
using vvi ... | replace | 111 | 112 | 111 | 112 | 0 | |
p02635 | 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;
typedef pair<int, int> P;
const int MOD = 998244353;
const int INF = 0x3f3f3f3f;
const ll INFL = 0x3f3f3f3f3f3f3f3f;
ll dp[400][400][400];
int a[400];
int d[400];
int main() {
string s;
cin >> s;
... | #include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
using namespace std;
typedef long long ll;
typedef pair<int, int> P;
const int MOD = 998244353;
const int INF = 0x3f3f3f3f;
const ll INFL = 0x3f3f3f3f3f3f3f3f;
ll dp[400][400][400];
int a[400];
int d[400];
int main() {
string s;
cin >> s;
... | insert | 28 | 28 | 28 | 29 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define ll long long int
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ordered_set \
tree<ll, null_type, less<ll>, rb_tree_tag, tree_order_statis... | #include <bits/stdc++.h>
using namespace std;
#define ll long long int
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ordered_set \
tree<ll, null_type, less<ll>, rb_tree_tag, tree_order_statis... | replace | 49 | 50 | 49 | 50 | 0 | |
p02635 | C++ | Runtime Error | #include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <complex>
#include <cstdio>
#include <cstring>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <limits.h>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <random>
#... | #include <algorithm>
#include <array>
#include <bitset>
#include <cassert>
#include <complex>
#include <cstdio>
#include <cstring>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <limits.h>
#include <map>
#include <math.h>
#include <numeric>
#include <queue>
#include <random>
#... | replace | 248 | 249 | 248 | 249 | 0 | |
p02635 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = a; i < (b); ++i)
#define trav(a, x) for (auto &a : (x))
#define all(x) x.begin(), x.end() // sort(all(x))
#define sz(x) (int)(x).size()
#define mp(x, y) make_pair((x), (y))
typedef long long ll;
typedef double T;
typedef pair<int, int> p... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = a; i < (b); ++i)
#define trav(a, x) for (auto &a : (x))
#define all(x) x.begin(), x.end() // sort(all(x))
#define sz(x) (int)(x).size()
#define mp(x, y) make_pair((x), (y))
typedef long long ll;
typedef double T;
typedef pair<int, int> p... | replace | 153 | 154 | 153 | 154 | TLE | |
p02635 | C++ | Runtime Error | #include <iostream>
#include <string>
#include <vector>
using namespace std;
typedef long long ll;
const int MOD = 998244353; // change if needed
struct Modint {
ll val;
Modint(ll _val = 0) : val(_val % MOD) {}
Modint operator+(Modint other) const { return Modint(val + other.val); }
void operator+=(Modin... | #include <iostream>
#include <string>
#include <vector>
using namespace std;
typedef long long ll;
const int MOD = 998244353; // change if needed
struct Modint {
ll val;
Modint(ll _val = 0) : val(_val % MOD) {}
Modint operator+(Modint other) const { return Modint(val + other.val); }
void operator+=(Modin... | replace | 148 | 149 | 148 | 149 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define FOR(i, a, b) for (int i = (a); i < (b); ++i)
#define rep(i, n) FOR(i, 0, n)
#define rrep(i, n) for (int i = ((int)(n)-1); i >= 0; --i)
#define whole(x) (x).begin(), (x).end()
#define UNIQUE(v) v.erase(unique(v.begin(), v.end()), v.end())
using ... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define FOR(i, a, b) for (int i = (a); i < (b); ++i)
#define rep(i, n) FOR(i, 0, n)
#define rrep(i, n) for (int i = ((int)(n)-1); i >= 0; --i)
#define whole(x) (x).begin(), (x).end()
#define UNIQUE(v) v.erase(unique(v.begin(), v.end()), v.end())
using ... | insert | 101 | 101 | 101 | 105 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
const int maxN = 305, mod = 998244353;
int n, m;
int f[2][maxN + 1][maxN + 1];
int a[maxN + 1], cnt;
char s[maxN + 1];
inline void update(int &x, int y) { x = x + y >= mod ? x + y - mod : x + y; }
int main() {
scanf("%s %d", s + 1, &m);
n = strlen(s + 1);
int l =... | #include <bits/stdc++.h>
using namespace std;
const int maxN = 305, mod = 998244353;
int n, m;
int f[2][maxN + 1][maxN + 1];
int a[maxN + 1], cnt;
char s[maxN + 1];
inline void update(int &x, int y) { x = x + y >= mod ? x + y - mod : x + y; }
int main() {
scanf("%s %d", s + 1, &m);
n = strlen(s + 1);
m = min(... | insert | 15 | 15 | 15 | 16 | 0 | |
p02635 | C++ | Runtime Error | // header
#ifdef LOCAL
#include "/Users/takakurashokichi/Desktop/atcoder/cxx-prettyprint-master/prettyprint.hpp"
#define debug(x) cout << x << endl
#else
#define debug(...) 42
#endif
#pragma GCC optimize("Ofast")
#include <bits/stdc++.h>
// types
using namespace std;
using ll = long long;
using ull = unsigned long long... | // header
#ifdef LOCAL
#include "/Users/takakurashokichi/Desktop/atcoder/cxx-prettyprint-master/prettyprint.hpp"
#define debug(x) cout << x << endl
#else
#define debug(...) 42
#endif
#pragma GCC optimize("Ofast")
#include <bits/stdc++.h>
// types
using namespace std;
using ll = long long;
using ull = unsigned long long... | replace | 258 | 260 | 258 | 260 | 0 | |
p02635 | C++ | Time Limit Exceeded | #include <algorithm>
#include <cstdint>
#include <cstdlib>
#include <iostream>
#include <string>
#include <vector>
template <typename T> void fin(T const &t) {
std::cout << t << std::endl;
exit(0);
}
template <typename T>
std::vector<std::vector<T>> mk2d(size_t s1, size_t s2, T const &val) {
std::vector<T> tmp(s... | #include <algorithm>
#include <cstdint>
#include <cstdlib>
#include <iostream>
#include <string>
#include <vector>
template <typename T> void fin(T const &t) {
std::cout << t << std::endl;
exit(0);
}
template <typename T>
std::vector<std::vector<T>> mk2d(size_t s1, size_t s2, T const &val) {
std::vector<T> tmp(s... | replace | 81 | 83 | 81 | 83 | TLE | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, n) for (int i = a; i < n; i++)
#define per(i, a, n) for (int i = n - 1; i >= a; i--)
#define pb push_back
#define mp make_pair
#define all(x) (x).begin(), (x).end()
#define SZ(x) ((int)(x).size())
#define fi first
#define se second
typedef vector<int> VI;
... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, n) for (int i = a; i < n; i++)
#define per(i, a, n) for (int i = n - 1; i >= a; i--)
#define pb push_back
#define mp make_pair
#define all(x) (x).begin(), (x).end()
#define SZ(x) ((int)(x).size())
#define fi first
#define se second
typedef vector<int> VI;
... | replace | 54 | 55 | 54 | 55 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
// #pragma GCC optimize("Ofast")
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#define ms(s, n) memset(s, n, sizeof(s))
#define FOR(i, a, b) for (int i = (a); i < (b); ++i)
#define FORd(i, a, b) for (int i = (a)-1; i >= (b); --i)
#define ... | #include <bits/stdc++.h>
using namespace std;
// #pragma GCC optimize("Ofast")
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
#define ms(s, n) memset(s, n, sizeof(s))
#define FOR(i, a, b) for (int i = (a); i < (b); ++i)
#define FORd(i, a, b) for (int i = (a)-1; i >= (b); --i)
#define ... | insert | 96 | 96 | 96 | 97 | 0 |
Time elapsed: 24ms
|
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define ff first
#define ss second
#define all(x) (x).begin(), (x).end()
#define len(x) int((x).size())
ll dp_real[2][301][301];
ll dp_suff[2][301][301];
ll dp_diag[2][301][301];
const ll p = 998244353LL;
int main() {
ios_base::sync_with_stdio(0... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define ff first
#define ss second
#define all(x) (x).begin(), (x).end()
#define len(x) int((x).size())
ll dp_real[2][301][301];
ll dp_suff[2][301][301];
ll dp_diag[2][301][301];
const ll p = 998244353LL;
int main() {
ios_base::sync_with_stdio(0... | insert | 28 | 28 | 28 | 30 | 0 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define pii pair<int, int>
#define ull unsigned ll
#define f first
#define s second
#define ALL(x) x.begin(), x.end()
#define SZ(x) (int)x.size()
#define SQ(x) (x) * (x)
#define MN(a, b) a = min(a, (__typeof__(a))(b))
#define MX(a, b) a = max(a, (__type... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define pii pair<int, int>
#define ull unsigned ll
#define f first
#define s second
#define ALL(x) x.begin(), x.end()
#define SZ(x) (int)x.size()
#define SQ(x) (x) * (x)
#define MN(a, b) a = min(a, (__typeof__(a))(b))
#define MX(a, b) a = max(a, (__type... | replace | 101 | 102 | 101 | 102 | 0 | |
p02635 | C++ | Runtime Error | #pragma GCC target("avx2")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("O3")
#include "bits/stdc++.h"
#include <random>
#include <unordered_map>
#include <unordered_set>
using namespace std;
typedef long long ll;
const ll MOD = /*1'000'000'007LL;*/ 998'244'353LL;
#define pb push_back
#define mp make_pair
... | #pragma GCC target("avx2")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("O3")
#include "bits/stdc++.h"
#include <random>
#include <unordered_map>
#include <unordered_set>
using namespace std;
typedef long long ll;
const ll MOD = /*1'000'000'007LL;*/ 998'244'353LL;
#define pb push_back
#define mp make_pair
... | insert | 72 | 72 | 72 | 76 | -11 | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
#define pb push_back
#define int long long
using namespace std;
const int N = 3e2 + 5;
int n, a[N], dp[N][N][N], pref[N];
const int M = 998244353;
signed main() {
ios_base::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
string S;
int k;
cin >> S >> k;
int cur = 0;
for (int i = ... | #include <bits/stdc++.h>
#define pb push_back
#define int long long
using namespace std;
const int N = 3e2 + 5;
int n, a[N], dp[N][N][N], pref[N];
const int M = 998244353;
signed main() {
ios_base::sync_with_stdio(0);
cin.tie(0);
cout.tie(0);
string S;
int k;
cin >> S >> k;
int sz = S.size();
k = min... | insert | 17 | 17 | 17 | 19 | -11 | |
p02635 | C++ | Memory Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
long d[333][666][666];
vector<int> u;
int p = 998244353;
int f(int i, int v, int w) {
if (!i)
return v ? 0 : 1;
if (v > w)
return 0;
if (d[i][v][w] >= 0)
return d[i][v][w];
d[i][v][w] = 0;
for (int j = max(-u[i - 1], -w); j <= v; j++)
(d[i][v][w] ... | #include <bits/stdc++.h>
using namespace std;
int d[333][666][666];
vector<int> u;
int p = 998244353;
int f(int i, int v, int w) {
if (!i)
return v ? 0 : 1;
if (v > w)
return 0;
if (d[i][v][w] >= 0)
return d[i][v][w];
d[i][v][w] = 0;
for (int j = max(-u[i - 1], -w); j <= v; j++)
(d[i][v][w] +... | replace | 3 | 4 | 3 | 4 | MLE | |
p02635 | C++ | Runtime Error | #include <bits/stdc++.h>
#define ull unchaed long long
#define ll long long
#define il inline
#define db double
#define ls rt << 1
#define rs rt << 1 | 1
#define pb push_back
#define mp make_pair
#define pii pair<int, int>
#define X first
#define Y second
#define pcc pair<char, char>
#define vi vector<int>
#define vl v... | #include <bits/stdc++.h>
#define ull unchaed long long
#define ll long long
#define il inline
#define db double
#define ls rt << 1
#define rs rt << 1 | 1
#define pb push_back
#define mp make_pair
#define pii pair<int, int>
#define X first
#define Y second
#define pcc pair<char, char>
#define vi vector<int>
#define vl v... | replace | 54 | 55 | 54 | 55 | 0 | |
p02635 | C++ | Runtime Error |
#include <bits/stdc++.h>
using namespace std;
#ifdef Adrian
#include "debug.h"
#else
#define debug(...) 9999
#endif
typedef long long ll;
typedef long double ld;
typedef complex<ld> point;
#define F first
#define S second
#define ii pair<ll, ll>
template <typename G> struct triple {
G F, S, T;
};
#define iii trip... |
#include <bits/stdc++.h>
using namespace std;
#ifdef Adrian
#include "debug.h"
#else
#define debug(...) 9999
#endif
typedef long long ll;
typedef long double ld;
typedef complex<ld> point;
#define F first
#define S second
#define ii pair<ll, ll>
template <typename G> struct triple {
G F, S, T;
};
#define iii trip... | replace | 86 | 87 | 86 | 87 | 0 | |
p02635 | C++ | Runtime Error | #line 2 "lib/template.cpp"
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cmath>
#include <functional>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using VI = vector... | #line 2 "lib/template.cpp"
#include <algorithm>
#include <bitset>
#include <cassert>
#include <cmath>
#include <functional>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using VI = vector... | insert | 167 | 167 | 167 | 168 | -11 | |
p02635 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
typedef pair<int, int> pi;
typedef long long ll;
const ll mod = 998244353;
string s;
ll K, dp[305][305][305]; // groups, moves, carry
ll N, sz[305];
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cin >> s >> K;
int gn = 1, gz = 0;
N = s.size();
... | #include <bits/stdc++.h>
using namespace std;
typedef pair<int, int> pi;
typedef long long ll;
const ll mod = 998244353;
string s;
ll K, dp[305][305][305]; // groups, moves, carry
ll N, sz[305];
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cin >> s >> K;
int gn = 1, gz = 0;
N = s.size();
... | replace | 42 | 43 | 42 | 43 | TLE | |
p02636 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define forn(i, n) for (int i = 0; i < (int)(n); i++)
#define si(c) ((int)(c).size())
#define forsn(i, s, n) for (int i = (int)(s); i < ((int)n); i++)
#define dforsn(i, s, n) for (int i = (int)(n)-1; i >= ((int)s); i--)
#define all(c) (c).begin(), (c).end()
#define D(a) ce... | #include <bits/stdc++.h>
using namespace std;
#define forn(i, n) for (int i = 0; i < (int)(n); i++)
#define si(c) ((int)(c).size())
#define forsn(i, s, n) for (int i = (int)(s); i < ((int)n); i++)
#define dforsn(i, s, n) for (int i = (int)(n)-1; i >= ((int)s); i--)
#define all(c) (c).begin(), (c).end()
#define D(a) ce... | replace | 89 | 100 | 89 | 102 | -11 | |
p02636 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
const int N = 210;
typedef long long ll;
const int mod = 998244353;
inline int add(int a, int b) {
a += b;
return a >= mod ? a - mod : a;
}
inline int sub(int a, int b) {
a -= b;
return a < 0 ? a + mod : a;
}
inline int mul(int a, int b) { return 1ll * a * b % mod;... | #include <bits/stdc++.h>
using namespace std;
const int N = 310;
typedef long long ll;
const int mod = 998244353;
inline int add(int a, int b) {
a += b;
return a >= mod ? a - mod : a;
}
inline int sub(int a, int b) {
a -= b;
return a < 0 ? a + mod : a;
}
inline int mul(int a, int b) { return 1ll * a * b % mod;... | replace | 2 | 3 | 2 | 3 | 0 | |
p02637 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false), cin.tie(nullptr);
int k;
cin >> k;
vector<int> freq(k);
for (int &x : freq)
cin >> x;
int minv = 1000000, maxv = -1;
for (int x : freq) {
minv = min(minv, x);
maxv = max(maxv, x);
}
int sum = 0;
... | #include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false), cin.tie(nullptr);
int k;
cin >> k;
vector<int> freq(k);
for (int &x : freq)
cin >> x;
int minv = 1000000, maxv = -1;
for (int x : freq) {
minv = min(minv, x);
maxv = max(maxv, x);
}
int sum = 0;
... | insert | 65 | 65 | 65 | 66 | 0 | |
p02637 | C++ | Runtime Error | #include <algorithm>
#include <cassert>
#include <cstring>
#include <iostream>
#include <set>
#include <vector>
#define TRACE(x) std::cout << #x << " = " << x << "\n"
#define _ << " _ " <<
using namespace std;
bool possiblePrefix(vector<pair<int, int>> A, vector<int> prefix) {
int K = A.size();
vector<int> where... | #include <algorithm>
#include <cassert>
#include <cstring>
#include <iostream>
#include <set>
#include <vector>
#define TRACE(x) std::cout << #x << " = " << x << "\n"
#define _ << " _ " <<
using namespace std;
bool possiblePrefix(vector<pair<int, int>> A, vector<int> prefix) {
int K = A.size();
vector<int> where... | replace | 35 | 37 | 35 | 38 | 0 | |
p02637 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define int ll
#define rng(i, a, b) for (int i = int(a); i < int(b); i++)
#define rep(i, b) rng(i, 0, b)
#define gnr(i, a, b) for (int i = int(b) - 1; i >= int(a); i--)
#define per(i, b) gnr(i, 0, b)
#define pb push_back
#define eb emplace_back
#defi... | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
#define int ll
#define rng(i, a, b) for (int i = int(a); i < int(b); i++)
#define rep(i, b) rng(i, 0, b)
#define gnr(i, a, b) for (int i = int(b) - 1; i >= int(a); i--)
#define per(i, b) gnr(i, 0, b)
#define pb push_back
#define eb emplace_back
#defi... | replace | 267 | 268 | 267 | 270 | TLE | |
p02637 | C++ | Runtime Error | #include <algorithm>
#include <cmath>
#include <complex>
#include <cstdio>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
using namespace std;
#define MOD 1000000007
#define MOD2 998244353
#define PRIM 3
#define INF (1 << 29)
#d... | #include <algorithm>
#include <cmath>
#include <complex>
#include <cstdio>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
using namespace std;
#define MOD 1000000007
#define MOD2 998244353
#define PRIM 3
#define INF (1 << 29)
#d... | replace | 90 | 92 | 90 | 91 | 0 | |
p02637 | C++ | Runtime Error | #include <bits/stdc++.h>
#define debug(x) cerr << #x << " " << (x) << endl
using namespace std;
const int N = 1005, K = 105;
template <class T> void read(T &x) {
int sgn = 1;
char ch;
x = 0;
for (ch = getchar(); (ch < '0' || ch > '9') && ch != '-'; ch = getchar())
;
if (ch == '-')
ch = getchar(), sg... | #include <bits/stdc++.h>
#define debug(x) cerr << #x << " " << (x) << endl
using namespace std;
const int N = 10005, K = 10005;
template <class T> void read(T &x) {
int sgn = 1;
char ch;
x = 0;
for (ch = getchar(); (ch < '0' || ch > '9') && ch != '-'; ch = getchar())
;
if (ch == '-')
ch = getchar(),... | replace | 4 | 5 | 4 | 5 | 0 | |
p02637 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i < (b); ++i)
#define rrep(i, a, b) for (int i = (b); i-- > (a);)
#define all(v) (v).begin(), (v).end()
#define trav(x, v) for (auto &x : v)
#define sz(v) int(v.size())
typedef long long ll;
typedef vector<int> vi;
typedef pair<int, in... | #include <bits/stdc++.h>
using namespace std;
#define rep(i, a, b) for (int i = (a); i < (b); ++i)
#define rrep(i, a, b) for (int i = (b); i-- > (a);)
#define all(v) (v).begin(), (v).end()
#define trav(x, v) for (auto &x : v)
#define sz(v) int(v.size())
typedef long long ll;
typedef vector<int> vi;
typedef pair<int, in... | replace | 45 | 46 | 45 | 46 | 0 | |
p02638 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int MOD;
inline int add(int a, int b) {
a += b;
return a >= MOD ? a - MOD : a;
}
inline int sub(int a, int b) {
a -= b;
return a < 0 ? a + MOD : a;
}
inline int mul(int a, int b) { return 1ll * a * b % MOD; }
int ksm(int a, int b) {
int ans = 1;
for (; b; b >>= ... | #include <bits/stdc++.h>
using namespace std;
int MOD;
inline int add(int a, int b) {
a += b;
return a >= MOD ? a - MOD : a;
}
inline int sub(int a, int b) {
a -= b;
return a < 0 ? a + MOD : a;
}
inline int mul(int a, int b) { return 1ll * a * b % MOD; }
int ksm(int a, int b) {
int ans = 1;
for (; b; b >>= ... | replace | 19 | 20 | 19 | 20 | 0 | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
int a[5];
for (int i = 0; i < 5; i++)
cin >> a[i];
for (int i = 0; i < 5; i++) {
if (a[i] == 0)
return i + 1;
}
}
| #include <bits/stdc++.h>
using namespace std;
#define ll long long
int main() {
int a[5];
for (int i = 0; i < 5; i++)
cin >> a[i];
for (int i = 0; i < 5; i++) {
if (a[i] == 0) {
cout << i + 1;
break;
}
}
}
| replace | 10 | 12 | 10 | 14 | 1 | |
p02639 | C++ | Runtime Error | #include <iostream>
using namespace std;
int main() {
int x[5];
for (int i = 1; i <= 5; ++i)
cin >> x[i];
for (int i = 1; i <= 5; ++i) {
if (!x[i])
cout << i << '\n';
}
return 0;
} | #include <iostream>
using namespace std;
int main() {
int x[6];
for (int i = 1; i <= 5; ++i)
cin >> x[i];
for (int i = 1; i <= 5; ++i) {
if (!x[i])
cout << i << '\n';
}
return 0;
} | replace | 5 | 6 | 5 | 6 | 0 | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
int ara[5], i, c = 0;
for (i = 1; i <= 5; i++) {
cin >> ara[i];
}
for (i = 1; i <= 5; i++) {
if (ara[i] == 0)
cout << i << endl;
}
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int x1, x2, x3, x4, x5;
cin >> x1 >> x2 >> x3 >> x4 >> x5;
if (x1 == 0)
cout << 1 << endl;
else if (x2 == 0)
cout << 2 << endl;
else if (x3 == 0)
cout << 3 << endl;
else if (x4 == 0)
cout << 4 << endl;
else if (x5 == 0)
cout <... | replace | 3 | 12 | 3 | 16 | 0 | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> result;
for (int i = 0; i < 5; i++) {
cin >> result.at(i);
if (result.at(i) == 0) {
cout << i + 1 << endl;
break;
}
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> result(5);
for (int i = 0; i < 5; i++) {
cin >> result.at(i);
if (result.at(i) == 0) {
cout << i + 1 << endl;
break;
}
}
} | replace | 3 | 4 | 3 | 4 | -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)
|
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
int a[5];
for (int i = 1; i <= 5; i++) {
cin >> a[i];
if (a[i] == 0)
cout << i;
}
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int a[6];
for (int i = 1; i <= 5; i++) {
cin >> a[i];
if (a[i] == 0)
cout << i;
}
return 0;
} | replace | 4 | 5 | 4 | 5 | 0 | |
p02639 | C++ | Time Limit Exceeded | #include <iostream>
using namespace std;
int main() {
while (true) {
int num;
for (int i = 1; i <= 5; i++) {
cin >> num;
if (num == 0)
cout << i << endl;
}
}
} | #include <iostream>
using namespace std;
int main() {
int var[5];
while (cin >> var[0] >> var[1] >> var[2] >> var[3] >> var[4]) {
for (int i = 0; i < 5; i++) {
if (var[i] == 0)
cout << i + 1 << endl;
}
}
} | replace | 4 | 10 | 4 | 9 | TLE | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
int v, ans = -1;
for (int i = 0; i < 5; i++) {
cin >> v;
if (v == 0) {
ans = i;
}
}
return ans;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int v, ans = -1;
for (int i = 0; i < 5; i++) {
cin >> v;
if (v == 0) {
ans = i;
}
}
cout << ans + 1;
return 0;
} | replace | 12 | 13 | 12 | 14 | 0 | |
p02639 | C++ | Runtime Error | // #include <bits/stdc++.h>
#include <algorithm>
#include <cmath>
#include <iomanip>
#include <ios>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <stack>
// #include <windows.h>
using namespace std;
template <class T> using V = vector<T>;
template <class T> using VV = V<V<T>>;
template... | // #include <bits/stdc++.h>
#include <algorithm>
#include <cmath>
#include <iomanip>
#include <ios>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <stack>
// #include <windows.h>
using namespace std;
template <class T> using V = vector<T>;
template <class T> using VV = V<V<T>>;
template... | replace | 127 | 128 | 127 | 128 | -11 | |
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
int main() {
int a[5];
int pri;
for (int i = 1; i <= 5; i++) {
cin >> a[i];
if (a[i] == 0)
pri = i;
}
cout << pri << endl;
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int a[10];
int pri;
for (int i = 1; i <= 5; i++) {
cin >> a[i];
if (a[i] == 0)
pri = i;
}
cout << pri << endl;
return 0;
}
| replace | 5 | 6 | 5 | 6 | TLE | |
p02639 | C++ | Time Limit Exceeded | #include <iostream>
using namespace std;
int main() {
int A[5];
int x = 0;
for (int i = 1; i <= 5; i++) {
cin >> A[i];
if (A[i] == 0)
x = i;
}
cout << x;
return 0;
} | #include <iostream>
using namespace std;
int main() {
int A[5];
int x = 0;
for (int i = 1; i <= 5; i++) {
cin >> A[i];
}
for (int i = 1; i <= 5; i++) {
if (A[i] == 0)
x = i;
}
cout << x;
return 0;
} | insert | 8 | 8 | 8 | 10 | TLE | |
p02639 | C++ | Runtime Error | #pragma GCC optimize("Ofast")
#include "bits/stdc++.h"
using namespace std;
using ll = long long;
using ull = unsigned long long;
#define PI 3.141592
#define all(a) (a).begin(), (a).end()
int main() {
vector<int> A;
for (int i = 0; i < 5; i++)
cin >> A[i];
for (int i = 0; i < 5; i++) {
if (A[i] == 0) {
... | #pragma GCC optimize("Ofast")
#include "bits/stdc++.h"
using namespace std;
using ll = long long;
using ull = unsigned long long;
#define PI 3.141592
#define all(a) (a).begin(), (a).end()
int main() {
vector<int> A(5);
for (int i = 0; i < 5; i++)
cin >> A[i];
for (int i = 0; i < 5; i++) {
if (A[i] == 0) ... | replace | 9 | 10 | 9 | 10 | -11 | |
p02639 | Python | Runtime Error | import sys
line = sys.stdin.readlines()[0].rstrip("\n")
print(line.split(" ").index("0", 1))
| import sys
line = sys.stdin.readlines()[0].rstrip("\n")
nums = line.split(" ")
print(nums.index("0") + 1)
| replace | 3 | 4 | 3 | 5 | ValueError: '0' is not in list | Traceback (most recent call last):
File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p02639/Python/s359632708.py", line 3, in <module>
print(line.split(" ").index("0", 1))
ValueError: '0' is not in list
|
p02639 | C++ | Time Limit Exceeded | #include <algorithm>
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <math.h>
#include <string>
#define pi 3.1415926535897932384626
#include <cmath>
#define test(t) while (t--)
#define ll long long int
#define in cin >>
#define out cout <<
#define en "\n"
#define sp " "
#define pb push_back... | #include <algorithm>
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <math.h>
#include <string>
#define pi 3.1415926535897932384626
#include <cmath>
#define test(t) while (t--)
#define ll long long int
#define in cin >>
#define out cout <<
#define en "\n"
#define sp " "
#define pb push_back... | replace | 45 | 53 | 45 | 57 | TLE | |
p02639 | C++ | Runtime Error | #pragma warning(disable : 4996)
#pragma comment(linker, "/STACK:336777216")
#pragma GCC optimize("Ofast")
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <functional>
using namespace std;
using namespace __gnu_pbds;
typedef long long ll;
#define int lon... | #pragma warning(disable : 4996)
#pragma comment(linker, "/STACK:336777216")
#pragma GCC optimize("Ofast")
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
#include <functional>
using namespace std;
using namespace __gnu_pbds;
typedef long long ll;
#define int lon... | replace | 79 | 80 | 79 | 80 | 0 | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ar array
void solve() {}
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
int x[5];
cin >> x[0] >> x[1] >> x[2] >> x[3] >> x[4];
for (int i = 0; i < 5; i++) {
if (x[i] == 0) {
cout << i + 1 << "\n";
return 1;
}
... | #include <bits/stdc++.h>
using namespace std;
#define ll long long
#define ar array
void solve() {}
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
int x[5];
cin >> x[0] >> x[1] >> x[2] >> x[3] >> x[4];
for (int i = 0; i < 5; i++) {
if (x[i] == 0) {
cout << i + 1 << "\n";
return 0;
}
... | replace | 16 | 17 | 16 | 17 | 1 | |
p02639 | C++ | Runtime Error | // --------------
// Tejas Pandey |
// 14 - 06 - 20 |
// Atcoder BC 170|
// --------------
#include <bits/stdc++.h>
using namespace std;
#define mod 1000000007
#define vi vector<int>
typedef long long int ll;
int main(void) {
// freopen("in.txt","r",stdin);
// freopen("out.txt","w",stdout);
ios_base::sync_wi... | // --------------
// Tejas Pandey |
// 14 - 06 - 20 |
// Atcoder BC 170|
// --------------
#include <bits/stdc++.h>
using namespace std;
#define mod 1000000007
#define vi vector<int>
typedef long long int ll;
int main(void) {
// freopen("in.txt","r",stdin);
// freopen("out.txt","w",stdout);
ios_base::sync_wi... | replace | 19 | 20 | 19 | 20 | -11 | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> x(4);
for (int i = 0; i < 5; i++) {
cin >> x.at(i);
}
int ans = 0;
for (int i = 0; i < 5; i++) {
if (x.at(i) == 0) {
ans = i + 1;
break;
}
}
cout << ans << endl;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
vector<int> x(5);
for (int i = 0; i < 5; i++) {
cin >> x.at(i);
}
int ans = 0;
for (int i = 0; i < 5; i++) {
if (x.at(i) == 0) {
ans = i + 1;
break;
}
}
cout << ans << endl;
} | replace | 4 | 5 | 4 | 5 | -6 | terminate called after throwing an instance of 'std::out_of_range'
what(): vector::_M_range_check: __n (which is 4) >= this->size() (which is 4)
|
p02639 | C++ | Runtime Error | #include <iostream>
using namespace std;
int main() {
ios_base::sync_with_stdio(0);
cin.tie(0);
int i, var[5];
for (i = 1; i <= 5; ++i) {
cin >> var[i];
if (var[i] == 0)
cout << i << "\n";
}
return 0;
}
| #include <iostream>
using namespace std;
int main() {
ios_base::sync_with_stdio(0);
cin.tie(0);
long long var;
for (int i = 1; i <= 5; ++i) {
cin >> var;
if (var == 0)
cout << i << "\n";
}
return 0;
}
| replace | 6 | 10 | 6 | 11 | 0 | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
int n = 0;
vector<int> vec(n);
for (int i = 0; i < 6; i++) {
cin >> vec.at(i);
if (vec.at(i) == 0) {
cout << i + 1 << endl;
}
}
return 0;
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int a, b, c, d, e;
cin >> a >> b >> c >> d >> e;
if (a == 0)
cout << 1 << endl;
if (b == 0)
cout << 2 << endl;
if (c == 0)
cout << 3 << endl;
if (d == 0)
cout << 4 << endl;
if (e == 0)
cout << 5 << endl;
return 0;
}
| replace | 4 | 12 | 4 | 16 | -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)
|
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
int main() {
int num;
while (1) {
for (int i = 1; i <= 5; i++) {
cin >> num;
if (num == 0) {
cout << i << endl;
break;
}
}
}
}
| #include <bits/stdc++.h>
using namespace std;
int main() {
int num;
while (1) {
for (int i = 1; i <= 5; i++) {
cin >> num;
if (num == 0) {
cout << i << endl;
break;
}
}
break;
}
}
| insert | 12 | 12 | 12 | 13 | TLE | |
p02639 | C++ | Time Limit Exceeded | #include <iostream>
#include <vector>
using namespace std;
int main() {
int in;
vector<int> v;
int s(0), save;
int i = 0;
while (i < 5) {
cin >> in;
s++;
v.push_back(in);
if (in == 0) {
save = s;
}
}
cout << save << "\n";
return 0;
} | #include <iostream>
#include <vector>
using namespace std;
int main() {
int in;
vector<int> v;
int s(0), save;
int i = 0;
while (i < 5) {
cin >> in;
s++;
v.push_back(in);
if (in == 0) {
save = s;
}
i++;
}
cout << save << "\n";
return 0;
} | insert | 15 | 15 | 15 | 16 | TLE | |
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
#define pp push_back
#define pf push_front
#define mp make_pair
#define fs first
#define sc second
#define sf scanf
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
typedef pair<int, int> ii;
const int N = (int)1e5;
const int INF = (int)1e9 + 7;
int main(int argc,... | #include <bits/stdc++.h>
#define pp push_back
#define pf push_front
#define mp make_pair
#define fs first
#define sc second
#define sf scanf
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
typedef pair<int, int> ii;
const int N = (int)1e5;
const int INF = (int)1e9 + 7;
int main(int argc,... | replace | 22 | 23 | 22 | 23 | TLE | |
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
#include <cmath>
#include <iostream>
#include <string>
#define ll long long
using namespace std;
int main() {
int arr[5];
arr[0] = -1333;
int ans = -1;
for (int i = 1; i < 6; i++) {
cin >> arr[i];
if (arr[i] == 0) {
ans = i;
}
}
cout << ans;
return 0;
}
| #include <bits/stdc++.h>
#include <cmath>
#include <iostream>
#include <string>
#define ll long long
using namespace std;
int main() {
int x1, x2, x3, x4, x5;
cin >> x1 >> x2 >> x3 >> x4 >> x5;
if (x1 == 0)
cout << "1";
else if (x2 == 0)
cout << "2";
else if (x3 == 0)
cout << "3";
else if (x4... | replace | 10 | 20 | 10 | 22 | TLE | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
int arr[5];
for (int i = 1; i <= 5; i++) {
cin >> arr[i];
if (arr[i] == 0) {
cout << i;
}
}
} | #include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
ll a, b, c, d, e;
cin >> a >> b >> c >> d >> e;
if (a == 0) {
cout << 1;
return 0;
} else if (b == 0) {
cout << 2;
return 0;
} else if (c == 0) {
cout << 3;
return 0;
} else if (d == 0) {
cout << 4;
... | replace | 4 | 10 | 4 | 21 | 0 | |
p02639 | Python | Runtime Error | nums = [int(x) for x in input()]
for i in range(5):
if nums[i] == 0:
print(i + 1)
exit(0)
| nums = [int(x) for x in input().split(" ")]
for i in range(5):
if nums[i] == 0:
print(i + 1)
exit(0)
| replace | 0 | 1 | 0 | 1 | ValueError: invalid literal for int() with base 10: ' ' | Traceback (most recent call last):
File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p02639/Python/s316600506.py", line 1, in <module>
nums = [int(x) for x in input()]
File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p02639/Python/s316600506.py", line 1, in <listcomp>
nu... |
p02639 | Python | Runtime Error | # -*- coding: utf-8 -*-
a, b, c, d, e = map(int, input().split())
suuji_list = ["", a, b, c, d, e]
print(list.index(0))
| # -*- coding: utf-8 -*-
a, b, c, d, e = map(int, input().split())
suuji_list = ["", a, b, c, d, e]
print(suuji_list.index(0))
| replace | 5 | 6 | 5 | 6 | TypeError: descriptor 'index' for 'list' objects doesn't apply to a 'int' object | Traceback (most recent call last):
File "/home/alex/Documents/bug-detection/input/Project_CodeNet/data/p02639/Python/s072466363.py", line 6, in <module>
print(list.index(0))
TypeError: descriptor 'index' for 'list' objects doesn't apply to a 'int' object
|
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
using namespace __gnu_pbds;
using namespace std;
#define int long long
#define mod 1000000007
#define FAST ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
#define f(i, n) for (int i = 0; i < n; i++)
#define fp(i, k, n) for (int i = k; i <= n; i++)
#def... | #include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
using namespace __gnu_pbds;
using namespace std;
#define int long long
#define mod 1000000007
#define FAST ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
#define f(i, n) for (int i = 0; i < n; i++)
#define fp(i, k, n) for (int i = k; i <= n; i++)
#def... | replace | 28 | 29 | 28 | 29 | TLE | |
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
#include <math.h>
#include <stdio.h>
using namespace std;
int main() {
vector<int> x(4);
for (int i = 0; i < 5; i++) {
cin >> x.at(i);
}
for (int i = 0; i < 5; i++) {
if (x.at(i) == 0) {
cout << i + 1;
break;
}
}
}
| #include <bits/stdc++.h>
#include <math.h>
#include <stdio.h>
using namespace std;
int main() {
vector<int> x(5);
for (int i = 0; i < 5; i++) {
cin >> x.at(i);
}
for (int i = 0; i < 5; i++) {
if (x.at(i) == 0) {
cout << i + 1;
break;
}
}
}
| replace | 7 | 8 | 7 | 8 | -6 | terminate called after throwing an instance of 'std::out_of_range'
what(): vector::_M_range_check: __n (which is 4) >= this->size() (which is 4)
|
p02639 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
int main() {
int arr[1000000000];
for (int i = 1; i <= 5; i++) {
cin >> arr[i];
}
for (int i = 1; i <= 5; i++) {
if (arr[i] == 0) {
cout << i;
}
}
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int arr[20];
for (int i = 1; i <= 5; i++) {
cin >> arr[i];
}
for (int i = 1; i <= 5; i++) {
if (arr[i] == 0) {
cout << i;
}
}
return 0;
} | replace | 5 | 6 | 5 | 6 | -11 | |
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
using namespace std;
int main() {
int x[5], ans;
for (int i = 1; i <= 5; i++) {
cin >> x[i];
if (x[i] == 0)
ans = i;
}
cout << ans << endl;
return 0;
} | #include <bits/stdc++.h>
using namespace std;
int main() {
int x[6];
int ans;
for (int i = 1; i <= 5; i++) {
cin >> x[i];
if (x[i] == 0)
ans = i;
}
cout << ans << endl;
return 0;
} | replace | 3 | 4 | 3 | 5 | TLE | |
p02639 | C++ | Time Limit Exceeded | // Remeber Choose Compiler: GCC9
#include <bits/stdc++.h>
using namespace std;
// Debug Output Utility
#ifdef LOCAL
#define dbg(args...) \
do { \
cout << #args << " -> "; ... | // Remeber Choose Compiler: GCC9
#include <bits/stdc++.h>
using namespace std;
// Debug Output Utility
#ifdef LOCAL
#define dbg(args...) \
do { \
cout << #args << " -> "; ... | replace | 47 | 48 | 47 | 48 | TLE | |
p02639 | C++ | Time Limit Exceeded | #include <bits/stdc++.h>
#define ll long long
#define fastio \
ios_base ::sync_with_stdio(false); \
cin.tie(0); \
cout.tie(0);
using namespace ... | #include <bits/stdc++.h>
#define ll long long
#define fastio \
ios_base ::sync_with_stdio(false); \
cin.tie(0); \
cout.tie(0);
using namespace ... | replace | 9 | 17 | 9 | 21 | TLE | |
p02640 | C++ | Time Limit Exceeded | #include <iostream>
using namespace std;
int X, Y;
bool dfs(int i, int sum) {
if (i == X)
return sum == Y;
if (dfs(i + 1, sum + 2))
return true;
if (dfs(i + 1, sum + 4))
return true;
return false;
}
int main() {
cin >> X >> Y;
if (Y / 4 > X) {
cout << "No";
return 0;
}
if (dfs(0, ... | #include <iostream>
using namespace std;
int X, Y;
bool dfs(int i, int sum) {
if (i == X)
return sum == Y;
if (dfs(i + 1, sum + 2))
return true;
if (dfs(i + 1, sum + 4))
return true;
return false;
}
int main() {
cin >> X >> Y;
if (Y >= X * 2 && Y <= X * 4 && Y % 2 == 0) {
if (dfs(0, 0))
... | replace | 17 | 24 | 17 | 21 | TLE | |
p02640 | C++ | Runtime Error | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i <= (int)(n); i++)
int main() {
int x, y;
cin >> x >> y;
rep(i, x) {
if (2 * i + 4 * (x - i) == y) {
cout << "Yes ";
exit(1);
}
}
cout << "No" << endl;
return 0;
} | #include <algorithm>
#include <iostream>
#include <vector>
using namespace std;
#define rep(i, n) for (int i = 0; i <= (int)(n); i++)
int main() {
int x, y;
cin >> x >> y;
rep(i, x) {
if (2 * i + 4 * (x - i) == y) {
cout << "Yes ";
return 0;
}
}
cout << "No" << endl;
return 0;
} | replace | 12 | 13 | 12 | 13 | 1 | |
p02640 | C++ | Runtime Error | /*
author : s@if
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
using namespace __gnu_pbds;
using namespace std;
#define NIL -1
#define fi first
#define sec second
#define MAX INT_MAX
#define INF 1e9
#define ll long long
#define PI acos(-1.0)
#define MOD 1000000007
#define PLL pair<ll, ll>... | /*
author : s@if
*/
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
using namespace __gnu_pbds;
using namespace std;
#define NIL -1
#define fi first
#define sec second
#define MAX INT_MAX
#define INF 1e9
#define ll long long
#define PI acos(-1.0)
#define MOD 1000000007
#define PLL pair<ll, ll>... | replace | 72 | 73 | 72 | 73 | TLE | |
p02640 | C++ | Runtime Error | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
#define pb push_back
#define mp make_pair
#define fast ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL);
#define ff first
#define ss second
#define INF (ll)(1e15)
#define mod (ll)(1e9 + 7)
#define endl "\n"
#define tt ... | #include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
#define pb push_back
#define mp make_pair
#define fast ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL);
#define ff first
#define ss second
#define INF (ll)(1e15)
#define mod (ll)(1e9 + 7)
#define endl "\n"
#define tt ... | insert | 31 | 31 | 31 | 32 | 0 | |
p02640 | Python | Time Limit Exceeded | from numba import jit
@jit
def solve(X, Y, Z):
while X >= 0:
if 2 * X + 4 * Z == Y:
return True
elif 2 * X + 4 * Z < Y:
X -= 1
Z += 1
return False
def main():
X, Y = map(int, input().split())
Z = 0
if solve(X, Y, Z):
print("Yes")
e... | from numba import jit
@jit
def solve(X, Y, Z):
while X >= 0:
if 2 * X + 4 * Z == Y:
return True
elif 2 * X + 4 * Z < Y:
X -= 1
Z += 1
else:
return False
return False
def main():
X, Y = map(int, input().split())
Z = 0
if sol... | insert | 11 | 11 | 11 | 13 | TLE | |
p02640 | C++ | Runtime Error | #include <bits/stdc++.h>
#define U(i, a, b) for (int i = (a); i <= (b); ++i)
#define D(i, a, b) for (int i = (a); i >= (b); --i)
using namespace std;
int gi() {
int f = 1, x = 0;
char ch = getchar();
while (ch < '0' || ch > '9') {
if (ch == '-')
f = -f;
ch = getchar();
}
while (ch >= '0' && ch <... | #include <bits/stdc++.h>
#define U(i, a, b) for (int i = (a); i <= (b); ++i)
#define D(i, a, b) for (int i = (a); i >= (b); --i)
using namespace std;
int gi() {
int f = 1, x = 0;
char ch = getchar();
while (ch < '0' || ch > '9') {
if (ch == '-')
f = -f;
ch = getchar();
}
while (ch >= '0' && ch <... | replace | 27 | 28 | 27 | 28 | 4 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.