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 "wall.h"
#include<bits/stdc++.h>
//#include "grader.cpp"
using namespace std;
void buildWall(int n, int k, int x[], int l[], int r[], int h[], int ans[]){
for(int i=0;i<k;i++)
{
if(x[i]==1)
{
for(int j=l[i];j<=r[i];j++)
ans[j]=max(ans[j],h[i]);
}
else
{
for(int j=l[i];j<=r[i];j++)
ans[j]=min(ans[j],h[i]);
}
}
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |