# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
125483 | songc | Long Mansion (JOI17_long_mansion) | C++14 | 1142 ms | 72740 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
typedef long long LL;
int N, Q;
int C[505050], S[2020202], E[2020202];
int L[505050], R[505050], chk[505050];
int LT[2020202], RT[2020202];
vector<int> key[505050];
void init(int id, int s, int e){
if (s == e){
LT[id] = L[s];
RT[id] = R[s];
return;
}
int mid = (s+e)/2;
init(id*2, s, mid);
init(id*2+1, mid+1, e);
LT[id] = min(LT[id*2], LT[id*2+1]);
RT[id] = max(RT[id*2], RT[id*2+1]);
}
int Lquery(int id, int s, int e, int ts, int te, int x){
if (e < ts || te < s || LT[id] > x) return -1;
if (s == e) return s;
int mid = (s+e)/2;
int ret = Lquery(id*2+1, mid+1, e, ts, te, x);
if (ret != -1) return ret;
return Lquery(id*2, s, mid, ts, te, x);
컴파일 시 표준 에러 (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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |