# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
364189 | cpp219 | Cake 3 (JOI19_cake3) | C++98 | 2493 ms | 12652 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#pragma GCC target ("avx2")
#pragma GCC optimization ("O3")
#pragma GCC optimization ("unroll-loops")
#include <bits/stdc++.h>
#define ll long long
#define ld long double
#define fs first
#define sc second
using namespace std;
const ll N = 2e5 + 69;
const ll mod = 1e16 + 7;
typedef pair<int,int> LL;
int n,m,id[N],cur = 1,lf,rg;
LL a[N],b[N];
struct Node{
ll val; int on;
};
Node st[1300000];
Node operator + (Node a,Node b){
Node c = {a.val + b.val,a.on + b.on};
return c;
}
void upd(int id,int l,int r,int u,int v){
if (l == r){
st[id].val += v;
if (v > 0) st[id].on++;
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |