This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "gap.h"
#include<bits/stdc++.h>
#define ll long long
using namespace std;
ll pl,pr;
ll l=0,r=1e18;
long long findGap(int T, int N)
{
ll mx=0;
if(T==1)
{
MinMax(l,r,&pl,&pr);
l=pl,r=pr;
for(int i=1;i<=N/2;i++){
MinMax(l,r,&pl,&pr);
mx=max({mx,pl-l,r-pr});
l=pl+1,r=pr-1;
}
}
return mx;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |