Submission #965106

# Submission time Handle Problem Language Result Execution time Memory
965106 2024-04-18T06:51:59 Z becaido Izvanzemaljci (COI21_izvanzemaljci) C++17
0 / 100
1 ms 348 KB
#pragma GCC optimize("O3,unroll-loops")
#pragma GCC target("avx,popcnt,sse4,abm")
#include <bits/stdc++.h>
using namespace std;

#ifdef WAIMAI
#define debug(HEHE...) cout << "[" << #HEHE << "] : ", dout(HEHE)
void dout() {cout << '\n';}
template<typename T, typename...U>
void dout(T t, U...u) {cout << t << (sizeof...(u) ? ", " : ""), dout(u...);}
#else
#define debug(...) 7122
#endif

#define ll long long
#define Waimai ios::sync_with_stdio(false), cin.tie(0)
#define FOR(x,a,b) for (int x = a, I = b; x <= I; x++)
#define pb emplace_back
#define F first
#define S second

const int SIZE = 1e5 + 5;

int n, k;
int x[SIZE], y[SIZE];

void solve() {
    cin >> n >> k;
    FOR (i, 1, n) cin >> x[i] >> y[i];
    if (k == 1) {
        int u, d, l, r;
        u = *min_element(x + 1, x + n + 1);
        d = *max_element(x + 1, x + n + 1);
        l = *min_element(y + 1, y + n + 1);
        r = *max_element(y + 1, y + n + 1);
        cout << u << ' ' << l << ' ' << max(d - u, r - l) << '\n';
        return;
    }
}

int main() {
    Waimai;
    solve();
}
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 344 KB Integer 0 violates the range [1, 2*10^9]
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 348 KB Unexpected end of file - int64 expected
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB Unexpected end of file - int64 expected
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 344 KB Unexpected end of file - int64 expected
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 1 ms 348 KB Unexpected end of file - int64 expected
2 Halted 0 ms 0 KB -