| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 | 
|---|---|---|---|---|---|---|---|
| 1099695 | dzhoz0 | 비밀 (JOI14_secret) | C++17 | 371 ms | 4436 KiB | 
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
/*
    ghmt the cutie :3
          UwU
*/
#include <bits/stdc++.h>
#include "secret.h"
using namespace std;
#define INF 1e9
#define f first
#define s second
#define pii pair<int, int>
#define vi vector<int>
const int MAXN = 1000;
const int LG = 9;
int st[LG + 1][MAXN];
void Init(int n, int a[]) {
    for(int i = 1; i <= n; i++) st[0][i] = a[i - 1];
    for(int j = 1; j <= LG; j++) 
        for(int i = 1; i + (1 << j) - 1 <= n; i++)
            st[j][i] = Secret(st[j - 1][i], st[j - 1][i + (1 << (j - 1))]);
}
int Query(int l, int r) {
    l++, r++;
    int len = r - l + 1;
    int s = -INF;
    for(int j = 0; (1 << j) <= len; j++) {
        if(len >> j & 1) {
            if(s == -INF) s = st[j][l];
            else s = Secret(s, st[j][l]);
            l = l + (1 << j);
        }
    }
    return s;
}
| # | Verdict | Execution time | Memory | Grader output | 
|---|---|---|---|---|
| Fetching results... | ||||
