# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
565503 | Spade1 | Gap (APIO16_gap) | C++14 | 58 ms | 1864 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include<bits/stdc++.h>
#include "gap.h"
#define pii pair<int, int>
#define pll pair<long long, long long>
#define ll long long
#define ld long double
#define st first
#define nd second
#define pb push_back
#define INF INT_MAX
using namespace std;
const int NN = 1e5 + 10;
ll a[NN];
int cnt = 0;
ll findGap(int T, int N) {
if (T == 1) {
ll mn, mx;
ll l = 0, r = 1e18;
for (ll i = 0; i < (N+1)/2; ++i) {
MinMax(l, r, &mn, &mx);
a[cnt++] = mn;
a[cnt++] = mx;
l = mn+1, r = mx - 1;
}
sort(a, a+N);
ll ans = 0;
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |