# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
310803 | ttnhuy313 | Pinball (JOI14_pinball) | C++14 | 745 ms | 20980 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
#define int long long
const int N = 1e5 + 5, oo = 1e18;
int n, a[N], b[N], c[N], d[N], dp1[N], dp2[N], tot, bound;
unordered_map <int, int> inv;
set <int> val;
struct SegmentTree {
int n;
vector <int> st;
SegmentTree() {}
SegmentTree(int _n) {
this -> n = _n;
st.assign(4 * n + 5, oo);
}
int Left(int x) {return (x << 1);}
int Right(int x) {return (x << 1) + 1;}
void update(int id, int L, int R, int i, int val) {
if (L > i || R < i) return;
if (L == R) {
st[id] = min(st[id], val);
return;
}
int mid = (L + R) >> 1;
update(Left(id), L, mid, i, val);
update(Right(id), mid + 1, R, i, val);
st[id] = min(st[Left(id)], st[Right(id)]);
# | 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... |