# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
125823 | dragoon | Gap (APIO16_gap) | C++14 | 83 ms | 5252 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "gap.h"
#include <vector>
#include <algorithm>
using namespace std;
typedef long long LL;
LL Solve1(int N) {
vector<LL> V(N, 0);
LL a = 0, b = 1000000000000000000LL;
a--, b++;
for (int i = 0, j = N - 1; i <= j; i++, j--) {
LL c, d;
MinMax(a, b, &c, &d);
V[i] = c;
V[j] = d;
a = c + 1;
b = d - 1;
}
LL ans = 0;
for (int i = 0; i < N - 1; i++) ans = max(ans, V[i + 1] - V[i]);
return ans;
}
LL Solve2(int N) {
vector<LL> V;
LL a = 0, b = 1000000000000000000LL;
a--, b++;
{
LL c, d;
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |