이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "gap.h"
#include <vector>
#include <iostream>
#include <assert.h>
using namespace std;
typedef long long ll;
ll INF=1000000000000000000;
ll x,y;
vector<ll> V;
long long findGap(int T, int N)
{
for(int i=0;i<N;i++){
MinMax(x,INF,&x,&y);
V.push_back(x);
assert(x!=-1);
x++;
}
x=0;
for(int i=0;i<N-1;i++)
x=max(x,V[i+1]-V[i]);
return x;
}
/*
1 6
1 2 5 7 8 12
*/
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |