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
p03161
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; using ll = long long; using vl = vector<ll>; using vvl = vector<vl>; using pll = pair<ll, ll>; using vb = vector<bool>; const ll oo = 0x3f3f3f3f3f3f3f3fLL; const double eps = 1e-9; #define sz(c) ll((c).size()) #define all(c) begin(c), end(c) #define mp make_pair #define pb ...
#include <bits/stdc++.h> using namespace std; using ll = long long; using vl = vector<ll>; using vvl = vector<vl>; using pll = pair<ll, ll>; using vb = vector<bool>; const ll oo = 0x3f3f3f3f3f3f3f3fLL; const double eps = 1e-9; #define sz(c) ll((c).size()) #define all(c) begin(c), end(c) #define mp make_pair #define pb ...
replace
19
20
19
20
TLE
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (n); i++) #define rep2(i, x, n) for (int i = x; i < (n); i++) #define ALL(n) begin(n), end(n) struct cww { cww() { ios::sync_with_stdio(false); cin.tie(0); } } star; const long long INF = numeric_limits<long long>::max(); in...
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (n); i++) #define rep2(i, x, n) for (int i = x; i < (n); i++) #define ALL(n) begin(n), end(n) struct cww { cww() { ios::sync_with_stdio(false); cin.tie(0); } } star; const long long INF = numeric_limits<long long>::max(); in...
replace
27
28
27
31
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int k; cin >> k; int h[n]; int cost[n]; for (int i = 0; i < n; i++) { cin >> h[i]; } for (int i = 0; i <= k; i++) { cost[i] = abs(h[i] - h[0]); } for (int i = k + 1; i < n; i++) { cost[i] = abs(h[i] - h[i - 1]...
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; int k; cin >> k; int h[n]; int cost[n]; for (int i = 0; i < n; i++) { cin >> h[i]; } for (int i = 0; i <= min(k, n - 1); i++) { cost[i] = abs(h[i] - h[0]); } for (int i = k + 1; i < n; i++) { cost[i] = abs(h[i...
replace
13
14
13
14
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int n, input, k; cin >> n; cin >> k; vector<int> h; for (int i = 0; i < n; i++) { cin >> input; h.push_back(input); } int dp[n]; for (int i = 0; i < n; i++) dp[i] = 1000000000; dp[1] = abs(h[1] - h[0]); dp[0] = 0; for (int j = ...
#include <bits/stdc++.h> using namespace std; int main() { int n, input, k; cin >> n; cin >> k; vector<int> h; for (int i = 0; i < n; i++) { cin >> input; h.push_back(input); } int dp[n]; for (int i = 0; i < n; i++) dp[i] = 1000000000; dp[1] = abs(h[1] - h[0]); dp[0] = 0; for (int j = ...
replace
17
18
17
18
0
p03161
C++
Runtime Error
#include <algorithm> #include <cmath> #include <cstdio> #include <cstring> #include <iomanip> #include <iostream> #define ll long long #define ull unsigned long long #define sl(a) scanf("%lld", &a); using namespace std; ll dp[10005], fr[10005]; int main() { ll n, i, j, k, l, m, mini = 100000000000; cin >> n >> k; ...
#include <algorithm> #include <cmath> #include <cstdio> #include <cstring> #include <iomanip> #include <iostream> #define ll long long #define ull unsigned long long #define sl(a) scanf("%lld", &a); using namespace std; ll dp[100005], fr[100005]; int main() { ll n, i, j, k, l, m, mini = 100000000000; cin >> n >> k;...
replace
10
11
10
11
0
p03161
C++
Runtime Error
#include <iostream> #include <vector> using namespace std; #define int long long template <class T> inline bool amin(T &a, T const &b) { if (a > b) { a = b; return 1; } return 0; } const int INF = 1001001001; signed main() { int n; cin >> n; int k; cin >> k; vector<int> a(n); for (int i =...
#include <iostream> #include <vector> using namespace std; #define int long long template <class T> inline bool amin(T &a, T const &b) { if (a > b) { a = b; return 1; } return 0; } const int INF = 1001001001; signed main() { int n; cin >> n; int k; cin >> k; vector<int> a(n); for (int i =...
replace
30
33
30
33
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ll long long int const N = 1e5 + 20; int const INF = 1e9 + 7; ll h[N], t, memo[N], k; int main() { memset(memo, INF, sizeof(memo)); cin >> t >> k; vector<ll> v(k); for (int i = 0; i < t; ++i) cin >> h[i]; int a = 1; for (auto &x : v) { x...
#include <bits/stdc++.h> using namespace std; #define ll long long int const N = 1e5 + 20; int const INF = 1e9 + 7; ll h[N], t, memo[N], k; int main() { memset(memo, INF, sizeof(memo)); cin >> t >> k; vector<ll> v(k); for (int i = 0; i < t; ++i) cin >> h[i]; int a = 1; for (auto &x : v) { x...
replace
29
30
29
30
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; const int INF = 1000000000; template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } return false; } int main() { ios::sync_with_stdio(false); cin.tie(0); int n, k; cin >> n >> k; vector<int> h(n); for (int i = 0; i <...
#include <bits/stdc++.h> using namespace std; const int INF = 1000000000; template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } return false; } int main() { ios::sync_with_stdio(false); cin.tie(0); int n, k; cin >> n >> k; vector<int> h(n); for (int i = 0; i <...
replace
25
26
25
26
0
p03161
C++
Runtime Error
#include <fstream> #include <iostream> #include <vector> using namespace std; // ifstream fin("test.in"); // #define int_max 0x3f3f3f3f // #define int_min -0x3f3f3f3f int main() { long long int n, k; cin >> n >> k; vector<long long int> heights(n + 1, 0); vector<long long int> dp(n + 1, 0); long long int ...
#include <fstream> #include <iostream> #include <vector> using namespace std; // ifstream fin("test.in"); // #define int_max 0x3f3f3f3f // #define int_min -0x3f3f3f3f int main() { long long int n, k; cin >> n >> k; vector<long long int> heights(n + 1, 0); vector<long long int> dp(n + 1, 0); long long int ...
replace
29
30
29
30
0
p03161
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; #define fast \ ios_base::sync_with_stdio(false); \ cin.tie(0) #define pb push_back #define mp make_pair #define ff first #define ss second #define debug(x) cout ...
#include <bits/stdc++.h> using namespace std; #define fast \ ios_base::sync_with_stdio(false); \ cin.tie(0) #define pb push_back #define mp make_pair #define ff first #define ss second #define debug(x) cout ...
replace
59
60
59
67
TLE
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef vector<long long> vll; typedef vector<int> vi; typedef pair<int, int> pi; #define pb push_back #define rep(i, l, n) for (int i = (l); i < n; i++) #define rep_cs(i, l, n) for (int i = (l); i <= n; i++) #define rep_d(j, n) for (int j = n; j >...
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef vector<long long> vll; typedef vector<int> vi; typedef pair<int, int> pi; #define pb push_back #define rep(i, l, n) for (int i = (l); i < n; i++) #define rep_cs(i, l, n) for (int i = (l); i <= n; i++) #define rep_d(j, n) for (int j = n; j >...
replace
63
65
63
65
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; // type definitions typedef long long ll; typedef vector<int> vi; typedef vector<ll> vll; typedef vector<vi> vvi; typedef pair<int, int> pii; typedef vector<pii> vpii; typedef complex<int> ci; typedef complex<double> cd; typedef complex<long double> cld; // macros #define...
#include <bits/stdc++.h> using namespace std; // type definitions typedef long long ll; typedef vector<int> vi; typedef vector<ll> vll; typedef vector<vi> vvi; typedef pair<int, int> pii; typedef vector<pii> vpii; typedef complex<int> ci; typedef complex<double> cd; typedef complex<long double> cld; // macros #define...
replace
100
101
100
101
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define rep(i, a, b) for (int i = (a); i < (int)(b); ++i) #define endl "\n" typedef long long ll; typedef string str; const double pi = 3.14159265358979323846; int ctoi(const char c) { if ('0' <= c && c <= '9') return (c - '0'); return -1; } vector<int> input(int n)...
#include <bits/stdc++.h> using namespace std; #define rep(i, a, b) for (int i = (a); i < (int)(b); ++i) #define endl "\n" typedef long long ll; typedef string str; const double pi = 3.14159265358979323846; int ctoi(const char c) { if ('0' <= c && c <= '9') return (c - '0'); return -1; } vector<int> input(int n)...
replace
279
280
279
282
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> #define vi vector<int> #define vvi vector<vi> #define forr(i, k, n) for (int i = k; i < n; i++) #define iforr(i, k, n) for (int i = n - 1; i >= k; i--) #define rep(i, n) forr(i, 0, n) #define irep(i, n) iforr(i, 0, n) #define aut(i, arr) for (auto &i : arr) #define all(arr) arr.begin(), arr.end...
#include <bits/stdc++.h> #define vi vector<int> #define vvi vector<vi> #define forr(i, k, n) for (int i = k; i < n; i++) #define iforr(i, k, n) for (int i = n - 1; i >= k; i--) #define rep(i, n) forr(i, 0, n) #define irep(i, n) iforr(i, 0, n) #define aut(i, arr) for (auto &i : arr) #define all(arr) arr.begin(), arr.end...
replace
37
38
37
38
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; void solve(std::istream &in, std::ostream &out); int main() { #ifdef LOCAL freopen("../IO/a.in", "r", stdin); // freopen("../IO/a.in", "w", stdout); #else std::ios_base::sync_with_stdio(false); std::cin.tie(nullptr); std::cout.tie(nullptr); #endif solve(std::ci...
#include <bits/stdc++.h> using namespace std; void solve(std::istream &in, std::ostream &out); int main() { #ifdef LOCAL freopen("../IO/a.in", "r", stdin); // freopen("../IO/a.in", "w", stdout); #else std::ios_base::sync_with_stdio(false); std::cin.tie(nullptr); std::cout.tie(nullptr); #endif solve(std::ci...
replace
30
31
30
31
0
p03161
C++
Runtime Error
#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; #define ll long long int #define fast ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL); #define MOD 1000000007 #define pb push_back #define S s...
#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; #define ll long long int #define fast ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL); #define MOD 1000000007 #define pb push_back #define S s...
replace
131
136
131
137
-11
p03161
C++
Runtime Error
#include <bits/stdc++.h> #include <climits> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #include <iostream> #define pb push_back #define f first #define s second #define pii pair<int, int> #define pll pair<ll, ll> #define vpll vector<pll> #define vi vector<int> #define vll vector<ll> #...
#include <bits/stdc++.h> #include <climits> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #include <iostream> #define pb push_back #define f first #define s second #define pii pair<int, int> #define pll pair<ll, ll> #define vpll vector<pll> #define vi vector<int> #define vll vector<ll> #...
replace
52
53
52
54
0
p03161
C++
Runtime Error
/*https://atcoder.jp/contests/dp/tasks/dp_b*/ #include <bits/stdc++.h> #include <sstream> #define FAST_IO \ ios_base::sync_with_stdio(false); \ cin.tie(NULL); ...
/*https://atcoder.jp/contests/dp/tasks/dp_b*/ #include <bits/stdc++.h> #include <sstream> #define FAST_IO \ ios_base::sync_with_stdio(false); \ cin.tie(NULL); ...
replace
53
54
53
54
0
p03161
C++
Runtime Error
#include <iostream> using namespace std; #define MAX 2000000000 int dp[10000]; int main() { int N, K; cin >> N >> K; int A[N]; for (int i = 0; N > i; i++) { cin >> A[i]; } for (int i = 0; N > i; i++) { dp[i] = MAX; } dp[0] = 0; for (int i = 0; N > i; i++) { for (int j = 0; min(K + i + 1, N...
#include <iostream> using namespace std; #define MAX 2000000000 int dp[100000]; int main() { int N, K; cin >> N >> K; int A[N]; for (int i = 0; N > i; i++) { cin >> A[i]; } for (int i = 0; N > i; i++) { dp[i] = MAX; } dp[0] = 0; for (int i = 0; N > i; i++) { for (int j = 0; min(K + i + 1, ...
replace
3
4
3
4
0
p03161
C++
Runtime Error
/* ...........__________ | ___ __ .............| | | | / .............| | | | / .............| | | __ | / _______ .............|_______| _______ _______ |______ ________ /| / | |/ | | .............| \ ...
/* ...........__________ | ___ __ .............| | | | / .............| | | | / .............| | | __ | / _______ .............|_______| _______ _______ |______ ________ /| / | |/ | | .............| \ ...
replace
64
65
64
65
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define watch(x) cerr << (#x) << ": " << (x) << endl #define int long long int32_t main() { int n, k; cin >> n >> k; vector<int> h(n); for (int i = 0; i < n; ++i) cin >> h[i]; vector<int> dp(n); dp[0] = 0; dp[1] = abs(h[1] - h[0]); for (int i = 2; i...
#include <bits/stdc++.h> using namespace std; #define watch(x) cerr << (#x) << ": " << (x) << endl #define int long long int32_t main() { int n, k; cin >> n >> k; vector<int> h(n); for (int i = 0; i < n; ++i) cin >> h[i]; vector<int> dp(n); dp[0] = 0; dp[1] = abs(h[1] - h[0]); for (int i = 2; i...
replace
20
21
20
21
0
p03161
C++
Runtime Error
#include <algorithm> #include <iostream> #include <limits.h> using namespace std; int main() { int n, k; cin >> n >> k; int h[100000]; int dp[100000]; for (int i = 0; i < n; i++) { cin >> h[i]; dp[i] = INT_MAX; } dp[0] = 0; for (int p = 0; p < n; p++) { for (int q = 1; q <= k; q++) { d...
#include <algorithm> #include <iostream> #include <limits.h> using namespace std; int main() { int n, k; cin >> n >> k; int h[100000]; int dp[100000]; for (int i = 0; i < n; i++) { cin >> h[i]; dp[i] = INT_MAX; } dp[0] = 0; for (int p = 0; p < n; p++) { for (int q = 1; q <= k; q++) { i...
insert
16
16
16
18
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)n; i++) #define rep2(i, m, n) for (int i = (int)m; i < (int)n; i++) typedef long long ll; typedef long double ld; typedef vector<int> vi; typedef vector<vi> vii; // 2次元配列 typedef vector<ll> vll; typedef vector<string> vs; const i...
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)n; i++) #define rep2(i, m, n) for (int i = (int)m; i < (int)n; i++) typedef long long ll; typedef long double ld; typedef vector<int> vi; typedef vector<vi> vii; // 2次元配列 typedef vector<ll> vll; typedef vector<string> vs; const i...
replace
26
28
26
28
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int N, K, dp[10001], h[10001]; fill(dp, dp + 10001, 1e9); dp[0] = 0; cin >> N >> K; for (int i = 0; i < N; i++) cin >> h[i]; for (int i = 0; i < N; i++) for (int k = 1; k <= K; k++) if (i + k < N) dp[i + k] = min(abs(h[i + k] -...
#include <bits/stdc++.h> using namespace std; int main() { long long N, K, dp[100001], h[100001]; fill(dp, dp + 100001, 1e9); dp[0] = 0; cin >> N >> K; for (int i = 0; i < N; i++) cin >> h[i]; for (int i = 0; i < N; i++) for (int k = 1; k <= K; k++) if (i + k < N) dp[i + k] = min(abs(h...
replace
3
5
3
5
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> // #pragma GCC optimize("O3") #pragma GCC optimize("Ofast") #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") #pragma GCC optimize("unroll-loops") #define pb push_back #define IOS \ ios_base::sync_w...
#include <bits/stdc++.h> // #pragma GCC optimize("O3") #pragma GCC optimize("Ofast") #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") #pragma GCC optimize("unroll-loops") #define pb push_back #define IOS \ ios_base::sync_w...
replace
91
92
91
92
0
p03161
C++
Runtime Error
#include <algorithm> #include <climits> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <iostream> #include <list> #include <map> #include <queue> #include <set> #include <stack> #include <string> #include <vector> #define REP(i, n) for (long long i = 0; i < n; ++i) #define REPR(i, n)...
#include <algorithm> #include <climits> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <iostream> #include <list> #include <map> #include <queue> #include <set> #include <stack> #include <string> #include <vector> #define REP(i, n) for (long long i = 0; i < n; ++i) #define REPR(i, n)...
replace
57
58
57
59
0
p03161
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; typedef long long ll; #define INF 1e18 #define MAX_N 100005 ll N, K, h[MAX_N], memo[MAX_N]; ll dp(int p) { if (p < 1) { return INF; } if (p == 1) { return 0; } if (p <= K + 1) { return abs(h[p] - h[1]); } ll opt = INF; for (int i = 1; i <= K;...
#include <bits/stdc++.h> using namespace std; typedef long long ll; #define INF 1e18 #define MAX_N 100005 ll N, K, h[MAX_N], memo[MAX_N]; ll dp(int p) { if (p < 1) { return INF; } if (p == 1) { return 0; } if (p <= K + 1) { return abs(h[p] - h[1]); } ll opt = INF; for (int i = 1; i <= K;...
replace
32
33
32
44
TLE
p03161
C++
Runtime Error
#include <algorithm> #include <cassert> #include <cctype> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <fstream> #include <iostream> #include <map> #include <queue> #include <set> #include <sstream> #include <stack> #include <string> #include <vector> #define all(c) (c).begin(), (c...
#include <algorithm> #include <cassert> #include <cctype> #include <cmath> #include <cstdio> #include <cstdlib> #include <cstring> #include <fstream> #include <iostream> #include <map> #include <queue> #include <set> #include <sstream> #include <stack> #include <string> #include <vector> #define all(c) (c).begin(), (c...
replace
33
34
33
34
0
p03161
C++
Runtime Error
#include <algorithm> #include <cmath> #include <iostream> using namespace std; typedef long long LL; const LL MAX = 100005; const LL INF = 1000 * 1000 * 1000 + 9; LL n, k, DP[MAX] = {}, stone[MAX] = {}; LL calc(LL idx) { if (DP[idx] != INF) return DP[idx]; else if (idx == n - 1) return DP[idx] = 0; e...
#include <algorithm> #include <cmath> #include <iostream> using namespace std; typedef long long LL; const LL MAX = 100005; const LL INF = 1000 * 1000 * 1000 + 9; LL n, k, DP[MAX] = {}, stone[MAX] = {}; LL calc(LL idx) { if (DP[idx] != INF) return DP[idx]; else if (idx == n - 1) return DP[idx] = 0; e...
replace
25
26
25
26
-11
p03161
C++
Runtime Error
// B - Frog 2 #include <bits/stdc++.h> using namespace std; #define rp(i, s, e) for (int i = (s); i < (e); ++i) #define chmin(x, y) x = min(x, y) int main() { int INF = 1e+9, N, K; cin >> N >> K; vector<int> H(N), dp(N, INF); rp(i, 0, N) cin >> H[i]; // i:[0,N-1] dp[0] = 0; rp(i, 1, N) { ...
// B - Frog 2 #include <bits/stdc++.h> using namespace std; #define rp(i, s, e) for (int i = (s); i < (e); ++i) #define chmin(x, y) x = min(x, y) int main() { int INF = 1e+9, N, K; cin >> N >> K; vector<int> H(N), dp(N, INF); rp(i, 0, N) cin >> H[i]; // i:[0,N-1] dp[0] = 0; rp(i, 1, N) { ...
replace
12
14
12
14
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> #include <stdio.h> using namespace std; typedef long long ll; typedef unsigned long long ull; #define all(v) ((v).begin()), ((v).end()) #define rall(v) ((v).rbegin()), ((v).rend()) #define clr(v, line) memset(v, line, sizeof(v)) #define endl '\n' #define TRACE #ifdef TRACE #define trace(...) __...
#include <bits/stdc++.h> #include <stdio.h> using namespace std; typedef long long ll; typedef unsigned long long ull; #define all(v) ((v).begin()), ((v).end()) #define rall(v) ((v).rbegin()), ((v).rend()) #define clr(v, line) memset(v, line, sizeof(v)) #define endl '\n' #define TRACE #ifdef TRACE #define trace(...) __...
replace
43
44
43
44
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } return false; } template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } return false; } const long long INF = 1LL << 60; long long...
#include <bits/stdc++.h> using namespace std; template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return true; } return false; } template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } return false; } const long long INF = 1LL << 60; long long...
replace
19
20
19
20
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define mp make_pair #define pb push_back #define ll unsigned long long int #define loop(i, a, b) for (int i = a; i < b; i++) int main() { int n, k; int h[100005]; cin >> n >> k; loop(i, 0, n) cin >> h[i]; ll dp[100005]; loop(i, 0, 100005) dp[i] = -1; dp[0] ...
#include <bits/stdc++.h> using namespace std; #define mp make_pair #define pb push_back #define ll unsigned long long int #define loop(i, a, b) for (int i = a; i < b; i++) int main() { int n, k; int h[100005]; cin >> n >> k; loop(i, 0, n) cin >> h[i]; ll dp[100005]; loop(i, 0, 100005) dp[i] = -1; dp[0] ...
replace
20
21
20
22
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return 1; } return 0; } template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return 1; } return 0; } typedef long long ll; #define EPS (1e-7) const long long ...
#include <bits/stdc++.h> using namespace std; template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return 1; } return 0; } template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return 1; } return 0; } typedef long long ll; #define EPS (1e-7) const long long ...
replace
42
43
42
43
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; typedef unsigned long long ull; typedef long long ll; #define fastio() \ ios_base::sync_with_stdio(0); \ cin.tie(0); ...
#include <bits/stdc++.h> using namespace std; typedef unsigned long long ull; typedef long long ll; #define fastio() \ ios_base::sync_with_stdio(0); \ cin.tie(0); ...
replace
22
25
22
26
0
p03161
C++
Runtime Error
#include <iostream> #define INF 1000001 using namespace std; int main() { int n = 0, k = 0, buf1 = 0; cin >> n >> k; int *dp = new int[n + 1]; dp[0] = 0; dp[1] = 0; int *h = new int[k + 1]; h[0] = INF; for (int i = 1; i < n + 1; ++i) { cin >> buf1; h[i] = buf1; } for (int i = 2; i < n + 1; ...
#include <iostream> #define INF 1000001 using namespace std; int main() { int n = 0, k = 0, buf1 = 0; cin >> n >> k; int *dp = new int[n + 1]; dp[0] = 0; dp[1] = 0; int *h = new int[n + 1]; h[0] = INF; for (int i = 1; i < n + 1; ++i) { cin >> buf1; h[i] = buf1; } for (int i = 2; i < n + 1; ...
replace
10
11
10
11
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ll long long #define pb push_back #define mp make_pair int ABS(int a) { return max(a, -a); } ll ABS(ll a) { return max(a, -a); } double ABS(double a) { return max(a, -a); } const int N = 100005; int arr[N]; int dp[N]; int main() { #ifndef ONLINE_JUDGE freopen("i...
#include <bits/stdc++.h> using namespace std; #define ll long long #define pb push_back #define mp make_pair int ABS(int a) { return max(a, -a); } ll ABS(ll a) { return max(a, -a); } double ABS(double a) { return max(a, -a); } const int N = 100005; int arr[N]; int dp[N]; int main() { /*#ifndef ONLINE_JUDGE freope...
replace
14
18
14
18
TLE
p03161
C++
Runtime Error
#define _CRT_SECURE_NO_WARNINGS #include <algorithm> #include <iostream> #include <iterator> #include <numeric> #include <sstream> #include <fstream> #include <cassert> #include <climits> #include <cstdlib> #include <cstring> #include <string> #include <cstdio> #include <vector> #include <math.h> #include <queue> #incl...
#define _CRT_SECURE_NO_WARNINGS #include <algorithm> #include <iostream> #include <iterator> #include <numeric> #include <sstream> #include <fstream> #include <cassert> #include <climits> #include <cstdlib> #include <cstring> #include <string> #include <cstdio> #include <vector> #include <math.h> #include <queue> #incl...
delete
59
63
59
59
0
FUCK YOU
p03161
C++
Runtime Error
#include <bits/stdc++.h> #define IO \ ios_base::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0) #define int long long using namespace ...
#include <bits/stdc++.h> #define IO \ ios_base::sync_with_stdio(0); \ cin.tie(0); \ cout.tie(0) #define int long long using namespace ...
replace
32
33
32
33
-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)
p03161
C++
Time Limit Exceeded
/* ,---, / _=_ \.~ (,(OvO),) ##} ,-\(-"-) /{ #)\ { '---' ( }\_ {{ ).___|__( '}} \_ { ) ( }} \ { / \ }} / { ) ( } / / ((_'_ _'_))_,\__\ */ // ____ _ _ _ _ ...
/* ,---, / _=_ \.~ (,(OvO),) ##} ,-\(-"-) /{ #)\ { '---' ( }\_ {{ ).___|__( '}} \_ { ) ( }} \ { / \ }} / { ) ( } / / ((_'_ _'_))_,\__\ */ // ____ _ _ _ _ ...
replace
53
54
53
59
TLE
p03161
C++
Runtime Error
#include <bits/stdc++.h> #define REP(i, n) for (int i = 0; i < (n); i++) #define RREP(i, s, n) for (int i = s; i < (n); i++) #define ALL(a) a.begin(), a.end() #define RALL(a) a.rbegin(), a.rend() #define maxs(x, y) x = max(x, y) #define mins(x, y) x = min(x, y) using namespace std; using ll = long long; typedef pair<in...
#include <bits/stdc++.h> #define REP(i, n) for (int i = 0; i < (n); i++) #define RREP(i, s, n) for (int i = s; i < (n); i++) #define ALL(a) a.begin(), a.end() #define RALL(a) a.rbegin(), a.rend() #define maxs(x, y) x = max(x, y) #define mins(x, y) x = min(x, y) using namespace std; using ll = long long; typedef pair<in...
replace
22
24
22
24
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> template <typename T> bool chmin(T &a, T b) { if (b < a) { a = b; return true; } return false; } std::vector<int> dp; int n, k; std::vector<int> vec(n + 1, 0); int INF = 1000000002; int main() { std::cin >> n >> k; dp.assign(100100, INF); for (int i = 0; i < n; i++) { ...
#include <bits/stdc++.h> template <typename T> bool chmin(T &a, T b) { if (b < a) { a = b; return true; } return false; } std::vector<int> dp; int n, k; std::vector<int> vec(100000 + 101, 0); int INF = 1000000002; int main() { std::cin >> n >> k; dp.assign(100100, INF); for (int i = 0; i < n; i++...
replace
12
13
12
13
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> #include <bitset> #include <map> #include <set> #define rep(i, a, b) for (i = a; i < b; i++) #define itrep(at) for (auto it = at.begin(); it != at.end(); it++) #define lli long long int #define pb push_back #define eb emplace_back #define mp make_pair #define db double #define M 1000000007 #def...
#include <bits/stdc++.h> #include <bitset> #include <map> #include <set> #define rep(i, a, b) for (i = a; i < b; i++) #define itrep(at) for (auto it = at.begin(); it != at.end(); it++) #define lli long long int #define pb push_back #define eb emplace_back #define mp make_pair #define db double #define M 1000000007 #def...
replace
63
64
63
64
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> #define ff first #define ss second #define pb push_back #define mp make_pair #define speedhack \ ios_base::sync_with_stdio(false); \ cin.tie(nullptr); #define fromfile ...
#include <bits/stdc++.h> #define ff first #define ss second #define pb push_back #define mp make_pair #define speedhack \ ios_base::sync_with_stdio(false); \ cin.tie(nullptr); #define fromfile ...
replace
25
26
25
26
0
p03161
C++
Runtime Error
#include <algorithm> #include <climits> #include <cstring> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <string> #include <vector> #define FOR(i, a, b) for (int i = int(a); i < int(b); i++) #define FORC(cont, it) \ ...
#include <algorithm> #include <climits> #include <cstring> #include <iostream> #include <map> #include <queue> #include <set> #include <stack> #include <string> #include <vector> #define FOR(i, a, b) for (int i = int(a); i < int(b); i++) #define FORC(cont, it) \ ...
replace
40
41
40
41
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define fastIO \ ios_base::sync_with_stdio(false); \ cin.tie(NULL) #define pb push_back #define ll long long int #define mod 1000000007 const int N = 1e5 + 5; in...
#include <bits/stdc++.h> using namespace std; #define fastIO \ ios_base::sync_with_stdio(false); \ cin.tie(NULL) #define pb push_back #define ll long long int #define mod 1000000007 const int N = 1e5 + 5; in...
delete
26
30
26
26
-11
p03161
C++
Runtime Error
#include <bits/stdc++.h> #define pb push_back #define int long long #define mp make_pair #define ff first #define ss second #define inf 9e18 #define pii pair<int, int> #define fastio \ ios_base::sync_with_stdio(0); ...
#include <bits/stdc++.h> #define pb push_back #define int long long #define mp make_pair #define ff first #define ss second #define inf 9e18 #define pii pair<int, int> #define fastio \ ios_base::sync_with_stdio(0); ...
replace
31
32
31
32
0
p03161
C++
Runtime Error
// includes #include <algorithm> #include <assert.h> #include <bitset> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <string> #include <tuple> #include <unordered_map> #include <vector> template <cl...
// includes #include <algorithm> #include <assert.h> #include <bitset> #include <cmath> #include <cstring> #include <iomanip> #include <iostream> #include <map> #include <numeric> #include <queue> #include <set> #include <stack> #include <string> #include <tuple> #include <unordered_map> #include <vector> template <cl...
replace
92
93
92
93
0
p03161
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define all(x) (x).begin(), (x).end() #define pb push_back typedef long long ll; const int INF = 1000000000; const long INF64 = 1000000000000000ll; const ll MOD = 1000000007ll; int main() { int n, k; std::cin >> n >>...
#include <bits/stdc++.h> using namespace std; #define rep(i, n) for (int i = 0; i < (int)(n); i++) #define all(x) (x).begin(), (x).end() #define pb push_back typedef long long ll; const int INF = 1000000000; const long INF64 = 1000000000000000ll; const ll MOD = 1000000007ll; int main() { int n, k; std::cin >> n >>...
replace
19
22
19
22
0
p03161
C++
Runtime Error
#include <algorithm> #include <climits> #include <cmath> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <stack> #include <string> #include <unordered_map> #include <vector> using namespace std; int main() { int n, k; cin >> n >> k; vector<int> dp(n, INT32_MAX), h(n); for (int ...
#include <algorithm> #include <climits> #include <cmath> #include <iomanip> #include <iostream> #include <map> #include <queue> #include <stack> #include <string> #include <unordered_map> #include <vector> using namespace std; int main() { int n, k; cin >> n >> k; vector<int> dp(n, INT32_MAX), h(n); for (int ...
replace
22
23
22
23
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> #define _GLIBCXX_DEBUG using namespace std; using ll = long long; using ld = long double; using P = pair<ll, ll>; // これを見る初心者の方へ:mainより上のいっぱい書いてあるやつはプログラムを簡略化するためのものです。自分も最近知りました。各種コメントをつけているので参考にしてみてください(検索すればqittaとかでも色々見つかるので探してみてください) // マクロ // forループ関係 // 引数は、(ループ内変数,動く範囲)か(ループ内変数,始めの数,終わり...
#include <bits/stdc++.h> #define _GLIBCXX_DEBUG using namespace std; using ll = long long; using ld = long double; using P = pair<ll, ll>; // これを見る初心者の方へ:mainより上のいっぱい書いてあるやつはプログラムを簡略化するためのものです。自分も最近知りました。各種コメントをつけているので参考にしてみてください(検索すればqittaとかでも色々見つかるので探してみてください) // マクロ // forループ関係 // 引数は、(ループ内変数,動く範囲)か(ループ内変数,始めの数,終わり...
replace
68
70
68
70
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; #define MAXN 100100 int n, a[MAXN][3], dp[MAXN][3], k; int main() { cin >> n; for (int i = 0; i < n; ++i) { for (int j = 0; j < 3; ++j) { cin >> a[i][j]; } } for (int i = 0; i < n; ++i) { for (int j = 0; j < n; ++j) { if (i == 0) { ...
#include <bits/stdc++.h> using namespace std; #define MAXN 100100 int n, a[MAXN][3], dp[MAXN][3], k; int main() { cin >> n; for (int i = 0; i < n; ++i) { for (int j = 0; j < 3; ++j) { cin >> a[i][j]; } } for (int i = 0; i < n; ++i) { for (int j = 0; j < 3; ++j) { if (i == 0) { ...
replace
14
15
14
15
TLE
p03162
C++
Runtime Error
/// Journey to the End of earth /// /// Gunjan Kumar /// #include <bits/stdc++.h> // #include <ext/pb_ds/assoc_container.hpp> // #include <ext/pb_ds/tree_policy.hpp> // #include <functional> // for less // using namespace __gnu_pbds; using namespace std; #define ll long long #define s(n) scanf("%d", &n) #define ls(...
/// Journey to the End of earth /// /// Gunjan Kumar /// #include <bits/stdc++.h> // #include <ext/pb_ds/assoc_container.hpp> // #include <ext/pb_ds/tree_policy.hpp> // #include <functional> // for less // using namespace __gnu_pbds; using namespace std; #define ll long long #define s(n) scanf("%d", &n) #define ls(...
delete
48
53
48
48
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef vector<long long> vl; typedef pair<long, long> pll; typedef vector<pll> vll; typedef set<ll> sl; typedef map<string, int> msi; #define pb push_back #define mp make_pair #define f first #define s second #define inf 0x3f3f3f3f #define gcd(a, b)...
#include <bits/stdc++.h> using namespace std; typedef long long ll; typedef vector<long long> vl; typedef pair<long, long> pll; typedef vector<pll> vll; typedef set<ll> sl; typedef map<string, int> msi; #define pb push_back #define mp make_pair #define f first #define s second #define inf 0x3f3f3f3f #define gcd(a, b)...
replace
26
28
26
28
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define clr(i, j) memset(i, j, sizeof(i)) #define pb push_back typedef long long ll; //-*-*-*-*-*-*-*-*- ll n; ll dp[10000][3]; ll arr[10000][3]; int main() { ll n, k; cin >> n; clr(dp, -1); for (int i = 0; i < n; i++) { cin >> arr[i][0] >> arr[i][1] >> arr...
#include <bits/stdc++.h> using namespace std; #define clr(i, j) memset(i, j, sizeof(i)) #define pb push_back typedef long long ll; //-*-*-*-*-*-*-*-*- ll n; ll dp[100000][3]; ll arr[100000][3]; int main() { ll n, k; cin >> n; clr(dp, -1); for (int i = 0; i < n; i++) { cin >> arr[i][0] >> arr[i][1] >> a...
replace
11
13
11
13
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; const int maxN = 10005; const int oo = 1e9 + 7; int dp[maxN][4]; int a[maxN][4]; int n; int main() { // freopen("Vacation.inp","r",stdin); // freopen("Vacation.out","w",stdout); cin >> n; for (int i = 1; i <= n; i++) for (int j = 1; j <= 3; j++) { cin >...
#include <bits/stdc++.h> using namespace std; const int maxN = 100005; const int oo = 1e9 + 7; int dp[maxN][4]; int a[maxN][4]; int n; int main() { // freopen("Vacation.inp","r",stdin); // freopen("Vacation.out","w",stdout); cin >> n; for (int i = 1; i <= n; i++) for (int j = 1; j <= 3; j++) { cin ...
replace
3
4
3
4
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ll long long #define pb push_back #define mp make_pair #define pl pair<ll, ll> #define vl vector<ll> #define fastIO \ ios_base::sync_with_stdio(false); \ c...
#include <bits/stdc++.h> using namespace std; #define ll long long #define pb push_back #define mp make_pair #define pl pair<ll, ll> #define vl vector<ll> #define fastIO \ ios_base::sync_with_stdio(false); \ c...
replace
11
12
11
12
0
p03162
C++
Runtime Error
#include <algorithm> #include <cstring> #include <iostream> #include <limits.h> #include <map> #include <queue> #include <set> #include <stdio.h> #include <utility> #include <vector> #define MAX_DOUBLE 40000000000.0 #include <math.h> #include <unistd.h> using namespace std; int min(int a, int b) { if (a > b) r...
#include <algorithm> #include <cstring> #include <iostream> #include <limits.h> #include <map> #include <queue> #include <set> #include <stdio.h> #include <utility> #include <vector> #define MAX_DOUBLE 40000000000.0 #include <math.h> #include <unistd.h> using namespace std; int min(int a, int b) { if (a > b) r...
replace
29
30
29
30
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> #define REP(i, n) for (int i = 0; i < n; i++) #define REPR(i, n) for (int i = n; i >= 0; i--) #define FOR(i, m, n) for (int i = m; i < n; i++) #define FORR(i, m, n) for (int i = m; i >= n; i--) #define SORT(v, n) sort(v, v + n); #define VSORT(v) sort(v.begin(), v.end()); #define VRSORT(v) sort(...
#include <bits/stdc++.h> #define REP(i, n) for (int i = 0; i < n; i++) #define REPR(i, n) for (int i = n; i >= 0; i--) #define FOR(i, m, n) for (int i = m; i < n; i++) #define FORR(i, m, n) for (int i = m; i >= n; i--) #define SORT(v, n) sort(v, v + n); #define VSORT(v) sort(v.begin(), v.end()); #define VRSORT(v) sort(...
replace
29
31
29
31
0
p03162
C++
Runtime Error
#include <algorithm> #include <iostream> using namespace std; int main() { int n, a[3][10000], h[3][10000]; cin >> n; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> a[j][i]; } } h[0][0] = a[0][0]; h[1][0] = a[1][0]; h[2][0] = a[2][0]; for (int i = 1; i < n; i++) { ...
#include <algorithm> #include <iostream> using namespace std; int main() { int n, a[3][100000], h[3][100000]; // int n,a[3][3]; cin >> n; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> a[j][i]; } } h[0][0] = a[0][0]; h[1][0] = a[1][0]; h[2][0] = a[2][0]; for (int i =...
replace
5
6
5
7
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; // M A F I A - M A F I A - M A F I A - M A F I A - M A F I A - M A F I A // #define int long long #define endl '\n' #define ff first #define ss second #define mp make_pair #define pb push_back #define vii vector<int> #define pii pair<int, int> #define vpii vector<pii> #...
#include <bits/stdc++.h> using namespace std; // M A F I A - M A F I A - M A F I A - M A F I A - M A F I A - M A F I A // #define int long long #define endl '\n' #define ff first #define ss second #define mp make_pair #define pb push_back #define vii vector<int> #define pii pair<int, int> #define vpii vector<pii> #...
delete
85
89
85
85
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; vector<vector<long long>> dp(n, vector<long long>(3, -1)); vector<vector<int>> h(n, vector<int>(3)); for (int i = 0; i < n; i++) for (int j = 0; j < 3; j++) cin >> h[i][j]; for (int i = 1; i < n; i++) { h[i][0] = h[i][...
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >> n; vector<vector<long long>> dp(n, vector<long long>(3, -1)); vector<vector<int>> h(n, vector<int>(3)); for (int i = 0; i < n; i++) for (int j = 0; j < 3; j++) cin >> h[i][j]; for (int i = 1; i < n; i++) { h[i][0] = h[i][...
replace
11
12
11
12
-11
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; #define mod 1000000007 #define pie 3.142857143 #define ll long long int #define fr(i, a, n) for (ll i = a; i < n; i++) #define vi vector<int> #define vlli vector<ll> #define pb push_back #define ppb pop_back #define mp make_pair #define fv(i, a) for (auto i : a) #define sz(...
#include <bits/stdc++.h> using namespace std; #define mod 1000000007 #define pie 3.142857143 #define ll long long int #define fr(i, a, n) for (ll i = a; i < n; i++) #define vi vector<int> #define vlli vector<ll> #define pb push_back #define ppb pop_back #define mp make_pair #define fv(i, a) for (auto i : a) #define sz(...
replace
34
35
34
41
TLE
p03162
C++
Runtime Error
/* Templatka c++ Kacper Fis // */ #include <bits/stdc++.h> using namespace std; const int INF = 1000000001; const float PI = 3.14; typedef long long LL; typedef vector<int> vi; typedef list<int> li; typedef queue<int> qi; typedef pair<int, int> ii; typedef map<string, int> msi; // np msi['nazwa'] = 'liczba' typed...
/* Templatka c++ Kacper Fis // */ #include <bits/stdc++.h> using namespace std; const int INF = 1000000001; const float PI = 3.14; typedef long long LL; typedef vector<int> vi; typedef list<int> li; typedef queue<int> qi; typedef pair<int, int> ii; typedef map<string, int> msi; // np msi['nazwa'] = 'liczba' typed...
replace
43
47
43
47
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(NULL); int n; cin >> n; int v1, v2, v3; int arr[3][n]; for (int i = 0; i < n; i++) { cin >> arr[i][0] >> arr[i][1] >> arr[i][2]; } v1 = arr[0][0]; v2 = arr[0][1]; v3 = arr[0][2]; for (int ...
#include <bits/stdc++.h> using namespace std; int main() { ios::sync_with_stdio(false); cin.tie(NULL); int n; cin >> n; int v1, v2, v3; int arr[n][3]; for (int i = 0; i < n; i++) { cin >> arr[i][0] >> arr[i][1] >> arr[i][2]; } v1 = arr[0][0]; v2 = arr[0][1]; v3 = arr[0][2]; for (int ...
replace
12
13
12
13
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int n, a, b, c; cin >> n; vector<vector<int>> inp(n, vector<int>(3)); for (int t = 0; t < n; t++) { cin >> a >> b >> c; inp[t][0] = a; inp[t][1] = b; inp[t][2] = c; } vector<vector<int>> dp(n, vector<int>(3)); dp[0][0] = inp[0][0...
#include <bits/stdc++.h> using namespace std; int main() { int n, a, b, c; cin >> n; vector<vector<int>> inp(n, vector<int>(3)); for (int t = 0; t < n; t++) { cin >> a >> b >> c; inp[t][0] = a; inp[t][1] = b; inp[t][2] = c; } vector<vector<int>> dp(n, vector<int>(3)); dp[0][0] = inp[0][0...
replace
23
24
23
24
-11
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; using ll = long long; const double pi = acos(-1); #define FOR(i, a, b) for (ll i = (a), __last_##i = (b); i < __last_##i; i++) #define RFOR(i, a, b) for (ll i = (b)-1, __last_##i = (a); i >= __last_##i; i--) #define REP(i, n) FOR(i, 0, n) #define RREP(i, n) RFOR(i, 0, n) #d...
#include <bits/stdc++.h> using namespace std; using ll = long long; const double pi = acos(-1); #define FOR(i, a, b) for (ll i = (a), __last_##i = (b); i < __last_##i; i++) #define RFOR(i, a, b) for (ll i = (b)-1, __last_##i = (a); i >= __last_##i; i--) #define REP(i, n) FOR(i, 0, n) #define RREP(i, n) RFOR(i, 0, n) #d...
replace
49
51
49
51
0
p03162
C++
Runtime Error
#include <cmath> #include <iostream> int main() { int cost[10000][3], N; int result[10000][3]; std::cin >> N; for (int i = 0; i < N; i++) { for (int j = 0; j < 3; j++) { std::cin >> cost[i][j]; } } for (int i = 0; i < 3; i++) result[0][i] = cost[0][i]; for (int i = 1; i < N; i++) { ...
#include <cmath> #include <iostream> int main() { int cost[100000][3], N; long long result[100000][3]; std::cin >> N; for (int i = 0; i < N; i++) { for (int j = 0; j < 3; j++) { std::cin >> cost[i][j]; } } for (int i = 0; i < 3; i++) result[0][i] = cost[0][i]; for (int i = 1; i < N; i...
replace
4
6
4
6
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> typedef long long ll; using namespace std; int main() { int n, k; cin >> n >> k; vector<vector<int>> happ(n, vector<int>(k)); int INF = 1 << 30; for (int i = 0; i < n; ++i) for (int j = 0; j < k; ++j) cin >> happ[i][j]; // dp[i][j] es la mayor felicidad del dia i con ...
#include <bits/stdc++.h> typedef long long ll; using namespace std; int main() { int n, k; cin >> n; // >> k; k = 3; vector<vector<int>> happ(n, vector<int>(k)); int INF = 1 << 30; for (int i = 0; i < n; ++i) for (int j = 0; j < k; ++j) cin >> happ[i][j]; // dp[i][j] es la mayor felicidad d...
replace
8
9
8
10
0
p03162
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 P = pair<int, int>; template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } return false; } int h[10010][3], dp[100100][3]; int main() { int n; cin ...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); ++i) using namespace std; using ll = long long; using P = pair<int, int>; template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return true; } return false; } int h[100100][3], dp[100100][3]; int main() { int n; cin...
replace
14
15
14
15
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ll long long #define pll pair<ll, ll> #define ff first #define ss second #define se set<ll> #define inf 10000000000000 int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); #ifdef APNA_IO freopen("input.txt", "r", stdin); freopen("output.txt", "w", ...
#include <bits/stdc++.h> using namespace std; #define ll long long #define pll pair<ll, ll> #define ff first #define ss second #define se set<ll> #define inf 10000000000000 int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); #ifdef APNA_IO freopen("input.txt", "r", stdin); freopen("output.txt", "w", ...
replace
36
37
36
37
0
p03162
C++
Runtime Error
#ifndef LOCAL #pragma GCC optimize("O3") #endif #include "bits/stdc++.h" using namespace std; #define sim template <class c #define ris return *this #define dor > debug &operator<< #define eni(x) \ sim > typename enable_if<sizeof dud<c>(0) x 1, debug &>:...
#ifndef LOCAL #pragma GCC optimize("O3") #endif #include "bits/stdc++.h" using namespace std; #define sim template <class c #define ris return *this #define dor > debug &operator<< #define eni(x) \ sim > typename enable_if<sizeof dud<c>(0) x 1, debug &>:...
replace
48
49
48
49
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; int memo[100100][5], n, a[100050], b[100050], c[100050]; // 0 swim // 1 Catch bugs // 2 homework int dp(int i, int last) { if (i > n) return 0; int Res1 = -2e9, Res2 = -2e9, Res3 = -2e9; if (last == 0) { Res1 = dp(i + 1, 1) + b[i]; Res2 = dp(i + 1, 2) + c...
#include <bits/stdc++.h> using namespace std; int memo[100100][5], n, a[100050], b[100050], c[100050]; // 0 swim // 1 Catch bugs // 2 homework int dp(int i, int last) { if (i > n) return 0; int Res1 = -2e9, Res2 = -2e9, Res3 = -2e9; if (memo[i][last] + 1) return memo[i][last]; if (last == 0) { Re...
insert
11
11
11
15
TLE
p03162
C++
Runtime Error
#include <bits/stdc++.h> #define pb push_back using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(0); #ifndef ONLINE_JUDGE freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout); freopen("error.txt", "w", stderr); #endif int n; cin >> n; int a[n], b[n], c[n], dp1[n],...
#include <bits/stdc++.h> #define pb push_back using namespace std; int main() { ios_base::sync_with_stdio(0); cin.tie(0); int n; cin >> n; int a[n], b[n], c[n], dp1[n], dp2[n], dp3[n]; for (int i = 0; i < n; i++) { cin >> a[i] >> b[i] >> c[i]; } dp1[0] = a[0]; dp2[0] = b[0]; dp3[0] = c[0]; ...
delete
7
13
7
7
0
p03162
C++
Runtime Error
// THIS IS MY NINJA WAY #include <algorithm> #include <bits/stdc++.h> #include <ctime> #include <vector> #define str string #define dbl double #define ll long long #define vl vector<ll> #define vs vector<str> #define pll pair<ll, ll> #define vll vector<pll> #define sl set<ll> #define pb push_back #define mp mak...
// THIS IS MY NINJA WAY #include <algorithm> #include <bits/stdc++.h> #include <ctime> #include <vector> #define str string #define dbl double #define ll long long #define vl vector<ll> #define vs vector<str> #define pll pair<ll, ll> #define vll vector<pll> #define sl set<ll> #define pb push_back #define mp mak...
replace
50
51
50
51
-11
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); // #ifndef ONLINE_JUDGE // freopen("input.txt", "r", stdin); // freopen("output.txt", "w", stdout); // #endif int n; cin >> n; int a[n][3]; for (int i = 0; i < n; i++) { cin >> a[...
#include <bits/stdc++.h> using namespace std; int main() { ios_base::sync_with_stdio(false); cin.tie(NULL); // #ifndef ONLINE_JUDGE // freopen("input.txt", "r", stdin); // freopen("output.txt", "w", stdout); // #endif int n; cin >> n; int a[n][3]; for (int i = 0; i < n; i++) { cin >> a[...
replace
47
48
47
48
210
p03162
C++
Runtime Error
#include <bits/stdc++.h> #include <deque> #include <iostream> #include <stdlib.h> #include <string> #define N 10005 #define ul unsigned long long #define ll long long int #define loop0(i, a, b) for (int i = a; i < b; ++i) #define loop1(i, a, b) for (int i = a; i <= b; ++i) #define ini0(i, b) for (int i = b; i >= 0; --i...
#include <bits/stdc++.h> #include <deque> #include <iostream> #include <stdlib.h> #include <string> #define N 100005 #define ul unsigned long long #define ll long long int #define loop0(i, a, b) for (int i = a; i < b; ++i) #define loop1(i, a, b) for (int i = a; i <= b; ++i) #define ini0(i, b) for (int i = b; i >= 0; --...
replace
5
6
5
6
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> #include <cstdio> #include <cstring> #include <cmath> #include <cstring> #include <chrono> #include <complex> #define endl "\n" #define ll long long int #define vi vector<int> #define vll vector<ll> #define vvi vector<vi> #define pii pair<int, int> #define pll pair<long long, long long> #defin...
#include <bits/stdc++.h> #include <cstdio> #include <cstring> #include <cmath> #include <cstring> #include <chrono> #include <complex> #define endl "\n" #define ll long long int #define vi vector<int> #define vll vector<ll> #define vvi vector<vi> #define pii pair<int, int> #define pll pair<long long, long long> #defin...
replace
63
67
63
83
TLE
p03162
C++
Runtime Error
// In the name of ALLAH the most merciful the most beneficial #include <bits/stdc++.h> #include <cstdio> #include <cstring> #include <fstream> #include <iostream> #include <math.h> #define sc(x) scanf("%d", &x) #define ll long long #define FOR(i, a, b) for (int i = a; i < b; i++) #define FORd(i, a, b) for (int i = a; ...
// In the name of ALLAH the most merciful the most beneficial #include <bits/stdc++.h> #include <cstdio> #include <cstring> #include <fstream> #include <iostream> #include <math.h> #define sc(x) scanf("%d", &x) #define ll long long #define FOR(i, a, b) for (int i = a; i < b; i++) #define FORd(i, a, b) for (int i = a; ...
replace
29
30
29
30
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); i++) using ll = long long; using namespace std; template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return 1; } return 0; } template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return 1; } ...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); i++) using ll = long long; using namespace std; template <class T> inline bool chmax(T &a, T b) { if (a < b) { a = b; return 1; } return 0; } template <class T> inline bool chmin(T &a, T b) { if (a > b) { a = b; return 1; } ...
replace
21
23
21
23
0
p03162
C++
Runtime Error
#include <iostream> using namespace std; int arr[10005][3]; int ans[10005][3]; int main() { int n; cin >> n; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> arr[i][j]; } } for (int i = 0; i < 3; i++) { ans[0][i] = arr[0][i]; } for (int i = 1; i < n; i++) { for (in...
#include <iostream> using namespace std; int arr[1000005][3]; int ans[1000005][3]; int main() { int n; cin >> n; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> arr[i][j]; } } for (int i = 0; i < 3; i++) { ans[0][i] = arr[0][i]; } for (int i = 1; i < n; i++) { for...
replace
3
5
3
5
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; #define ll long long #define mod 1000000007 vector<vector<int>> v; int dp[100001][3]; int f(int i, int j) { if (i == v.size()) return 0; if (dp[i][j] != -1) return dp[i][j]; int ans = INT_MIN; for (int k = 0; k < 3; k++) { if (k != j) { ans = ...
#include <bits/stdc++.h> using namespace std; #define ll long long #define mod 1000000007 vector<vector<int>> v; int dp[100001][3]; int f(int i, int j) { if (i == v.size()) return 0; if (dp[i][j] != -1) return dp[i][j]; int ans = INT_MIN; for (int k = 0; k < 3; k++) { if (k != j) { ans = ...
insert
22
22
22
23
TLE
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ll long long int #define fast \ ios_base::sync_with_stdio(false); \ cin.tie(NULL); #define mp make_pair #define pb push_back #define ld long double #de...
#include <bits/stdc++.h> using namespace std; #define ll long long int #define fast \ ios_base::sync_with_stdio(false); \ cin.tie(NULL); #define mp make_pair #define pb push_back #define ld long double #de...
replace
17
18
17
18
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #include <functional> using namespace std; #define int long long #define double long double #define FAST \ ios_base::sync_with_stdio(false); ...
#include <bits/stdc++.h> #include <ext/pb_ds/assoc_container.hpp> #include <ext/pb_ds/tree_policy.hpp> #include <functional> using namespace std; #define int long long #define double long double #define FAST \ ios_base::sync_with_stdio(false); ...
replace
51
52
51
52
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; template <class T> bool chmax(T &a, const T &b) { if (b > a) { a = b; return 1; } return 0; } template <class T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return 1; } return 0; } const long long INF = 2LL << 60; using ll = long long; usi...
#include <bits/stdc++.h> using namespace std; template <class T> bool chmax(T &a, const T &b) { if (b > a) { a = b; return 1; } return 0; } template <class T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return 1; } return 0; } const long long INF = 2LL << 60; using ll = long long; usi...
replace
21
22
21
22
0
p03162
C++
Runtime Error
#include <iostream> using namespace std; int main() { int n; cin >> n; long long a[100100][3]; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> a[i][j]; } } long long dp[100100][3] = {0}; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { for (int k = 0...
#include <iostream> using namespace std; int main() { int n; cin >> n; long long a[100100][3]; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> a[i][j]; } } long long dp[100100][3] = {0}; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { for (int k = 0...
replace
25
26
25
26
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; using ll = long long; template <class T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return 1; } return 0; } template <class T> bool chmax(T &a, const T &b) { if (a < b) { a = b; return 1; } return 0; } int main() { int n; cin >> n; ...
#include <bits/stdc++.h> using namespace std; using ll = long long; template <class T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return 1; } return 0; } template <class T> bool chmax(T &a, const T &b) { if (a < b) { a = b; return 1; } return 0; } int main() { int n; cin >> n; ...
replace
35
42
35
40
TLE
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define int long long const int N = 1e5 + 100; const int INF = 1e15; int dp[N][4], h[N][4], n, k; int sol(int idx, int p) { if (idx == n + 1) return 0; int &ans = dp[idx][p]; if (ans != -1) return ans; for (int i = 1; i <= 3; i++) { if (i != p) { ...
#include <bits/stdc++.h> using namespace std; #define int long long const int N = 1e5 + 100; const int INF = 1e15; int dp[N][4], h[N][4], n, k; int sol(int idx, int p) { if (idx == n + 1) return 0; int &ans = dp[idx][p]; if (ans != -1) return ans; for (int i = 1; i <= 3; i++) { if (i != p) { ...
delete
36
40
36
36
0
p03162
C++
Runtime Error
#include <algorithm> #include <cmath> #include <ctype.h> #include <deque> //<< fixed << setprecision() #include <iomanip> #include <iostream> #include <map> #include <queue> //priority_queue #include <set> #include <stack> #include <stdio.h> #include <string> #include <vector> typedef long long ll; using namespace std;...
#include <algorithm> #include <cmath> #include <ctype.h> #include <deque> //<< fixed << setprecision() #include <iomanip> #include <iostream> #include <map> #include <queue> //priority_queue #include <set> #include <stack> #include <stdio.h> #include <string> #include <vector> typedef long long ll; using namespace std;...
replace
58
59
58
59
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> using namespace std; vector<long long> a, b, c; vector<vector<long long>> happy; long long dp(int day, int prev) { if (day < 0) { return 0; } // if (happy[day][prev] != 0) { // return happy[day][prev]; // } if (prev == 0) { happy[day][prev] = max(dp(day - 1, 1) + b[day...
#include <bits/stdc++.h> using namespace std; vector<long long> a, b, c; vector<vector<long long>> happy; long long dp(int day, int prev) { if (day < 0) { return 0; } if (prev >= 0 && happy[day][prev] != 0) { return happy[day][prev]; } if (prev == 0) { happy[day][prev] = max(dp(day - 1, 1) + b[d...
replace
10
13
10
13
TLE
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int cost[10010][3]; long long happy[100010][3]; long long dp(int day, int prev) { if (day < 0) { return 0; } if (prev >= 0 && happy[day][prev] != 0) { return happy[day][prev]; } if (prev == 0) { happy[day][prev] = max(dp(day - 1, 1) + cost[da...
#include <bits/stdc++.h> using namespace std; int cost[100010][3]; long long happy[100010][3]; long long dp(int day, int prev) { if (day < 0) { return 0; } if (prev >= 0 && happy[day][prev] != 0) { return happy[day][prev]; } if (prev == 0) { happy[day][prev] = max(dp(day - 1, 1) + cost[d...
replace
3
4
3
4
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; using ll = long long; long double PI = 3.141592653589793238463; const int N = 1e5 + 5; const int MOD = 1e9 + 7; ll a[100005][5]; ll b[100005]; ll c[100005]; ll dp[100005][5]; int n, k; int D() { for (int i = 1; i <= n; i++) { for (int j = 1; j <= 3; j++) { for...
#include <bits/stdc++.h> using namespace std; using ll = long long; long double PI = 3.141592653589793238463; const int N = 1e5 + 5; const int MOD = 1e9 + 7; ll a[100005][5]; ll b[100005]; ll c[100005]; ll dp[100005][5]; int n, k; void D() { for (int i = 1; i <= n; i++) { for (int j = 1; j <= 3; j++) { fo...
replace
13
14
13
14
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); i++) using namespace std; const long long INF = (1 << 30); int main() { int n; cin >> n; int a[100000][3]; rep(i, n) { rep(j, 3) { cin >> a[i][j]; } } long long dp[100100][3] = {}; // 幸福度を0で初期化 rep(i, 3) { dp[0][i] = a[0][i]; } ...
#include <bits/stdc++.h> #define rep(i, n) for (int i = 0; i < (n); i++) using namespace std; const long long INF = (1 << 30); int main() { int n; cin >> n; int a[100000][3]; rep(i, n) { rep(j, 3) { cin >> a[i][j]; } } long long dp[100100][3] = {}; // 幸福度を0で初期化 rep(i, 3) { dp[0][i] = a[0][i]; } ...
replace
29
30
29
30
0
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> #define ll long long int #define f(i, n) for (ll i = 0; i < n; i++) #define fn(i, n) for (ll i = 1; i < n; i++) #define F first #define pb push_back #define S second using namespace std; ll dp[100005][4]; ll n; ll mn = INT_MAX; ll sol(ll a[][3], ll i, ll k) { if (i == n - 1) { if (k ==...
#include <bits/stdc++.h> #define ll long long int #define f(i, n) for (ll i = 0; i < n; i++) #define fn(i, n) for (ll i = 1; i < n; i++) #define F first #define pb push_back #define S second using namespace std; ll dp[100005][4]; ll n; ll mn = INT_MAX; ll sol(ll a[][3], ll i, ll k) { if (i == n - 1) { if (k ==...
replace
25
29
25
30
TLE
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; typedef long long ll; ll const mod = 1000000007; ll const md = 998244353; ll powmod(ll a, ll b) { ll res = 1; a %= mod; assert(b >= 0); for (; b; b >>= 1) { if (b & 1) res = res * a % mod; a = a * a % mod; } return res; } ifstream in("txt.in"); ofs...
#include <bits/stdc++.h> using namespace std; typedef long long ll; ll const mod = 1000000007; ll const md = 998244353; ll powmod(ll a, ll b) { ll res = 1; a %= mod; assert(b >= 0); for (; b; b >>= 1) { if (b & 1) res = res * a % mod; a = a * a % mod; } return res; } ifstream in("txt.in"); ofs...
replace
25
26
25
26
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define ll unsigned long long #define INF 1234567890 #define N (int)(1e5 + 5) #define pi acos(-1) void solve() { int dp[4]; int n; cin >> n; for (int i = 1; i <= 3; ++i) cin >> dp[i]; for (int i = 2; i <= n; ++i) { int cost[4], new_dp[4]; for (int j ...
#include <bits/stdc++.h> using namespace std; #define ll unsigned long long #define INF 1234567890 #define N (int)(1e5 + 5) #define pi acos(-1) void solve() { int dp[4]; int n; cin >> n; for (int i = 1; i <= 3; ++i) cin >> dp[i]; for (int i = 2; i <= n; ++i) { int cost[4], new_dp[4]; for (int j ...
replace
21
22
21
22
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> #include <iostream> using namespace std; int main() { int n; vector<vector<int>> a(n, vector<int>(3)), dp(n, vector<int>(3, INT_MIN)); for (int i = 0; i < n; i++) for (int j = 0; j < 3; j++) cin >> a[i][j]; dp[0][0] = a[0][0]; dp[0][1] = a[0][1]; dp[0][2] = a[0][2]; for ...
#include <bits/stdc++.h> #include <iostream> using namespace std; int main() { int n; cin >> n; vector<vector<int>> a(n, vector<int>(3)), dp(n, vector<int>(3, INT_MIN)); for (int i = 0; i < n; i++) for (int j = 0; j < 3; j++) cin >> a[i][j]; dp[0][0] = a[0][0]; dp[0][1] = a[0][1]; dp[0][2] = a[0...
insert
5
5
5
6
-11
p03162
C++
Time Limit Exceeded
#include <bits/stdc++.h> #define ll long long #define pb push_back #define all(v) v.begin(), v.end() #define mp make_pair #define ff first #define ss second #define MAXN 100005 #define endl "\n" using namespace std; ll n, a, b, c; vector<int> v[3]; ll dp[MAXN][4]; ll rec(int i, int p) { if (i == n) return 0; ll...
#include <bits/stdc++.h> #define ll long long #define pb push_back #define all(v) v.begin(), v.end() #define mp make_pair #define ff first #define ss second #define MAXN 100005 #define endl "\n" using namespace std; ll n, a, b, c; vector<int> v[3]; ll dp[MAXN][4]; ll rec(int i, int p) { if (i == n) return 0; if...
insert
16
16
16
18
TLE
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; int main() { int t = 1; // cin >> t; while (t--) { int n; cin >> n; vector<vector<int>> arr(n, vector<int>(3)); long long temp; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> temp; arr[i][j] = temp; ...
#include <bits/stdc++.h> using namespace std; int main() { int t = 1; // cin >> t; while (t--) { int n; cin >> n; vector<vector<int>> arr(n, vector<int>(3)); long long temp; for (int i = 0; i < n; i++) { for (int j = 0; j < 3; j++) { cin >> temp; arr[i][j] = temp; ...
replace
17
18
17
18
0
p03162
C++
Runtime Error
#include <bits/stdc++.h> using namespace std; #define fs first #define sc second #define mp make_pair #define pb push_back #define eb emplace_back #define ALL(A) A.begin(), A.end() #define RALL(A) A.rbegin(), A.rend() typedef long LL; typedef pair<LL, LL> P; const LL mod = 1e9 + 7; const LL LINF = 1LL << 62; const int ...
#include <bits/stdc++.h> using namespace std; #define fs first #define sc second #define mp make_pair #define pb push_back #define eb emplace_back #define ALL(A) A.begin(), A.end() #define RALL(A) A.rbegin(), A.rend() typedef long LL; typedef pair<LL, LL> P; const LL mod = 1e9 + 7; const LL LINF = 1LL << 62; const int ...
replace
22
23
22
23
-11