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<bits/stdc++.h>
using namespace std;
#define int long long
#define pb push_back
#define pii pair<int,int>
const int INF = 0x3f3f3f3f;
signed main(){
int n,k; cin >> n >> k;
int left=INF,right=-INF,up=-INF,down=INF;
for(int i=0; i<n; i++){
int a,b; cin >> a >> b;
left = min(left,a);
right = max(right,a);
up = max(up,b);
down = min(down,b);
}
cout << left << " " << down << " " << max(right-left, up-down) << '\n';
}
# | 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... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |