# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
553746 | QwertyPi | 운세 보기 2 (JOI14_fortune_telling2) | C++14 | 3081 ms | 256396 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
const int N = 2e5+3;
int A[N], B[N], C[N];
int x1[N], x2[N], pa[N];
map<int, int> M; int m;
// persistent segment tree
struct node{
node *l, *r;
int tl, tr, cnt;
node(int L, int R, int cnt) : l(nullptr), r(nullptr), tl(L), tr(R), cnt(cnt){};
~node(){};
};
void build(node*& t, int l, int r){
t = new node(l, r, 0);
if(l == r) return;
int mid = (l + r) / 2;
build(t->l, l, mid);
build(t->r, mid + 1, r);
}
node* upd(node* t, int tl, int tr, int q, int delta){
if(tl == tr){
node* ret = new node(tl, tr, (t ? t->cnt : 0) + delta);
return ret;
}
컴파일 시 표준 에러 (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... |