Submission #1329507

#TimeUsernameProblemLanguageResultExecution timeMemory
1329507lywoemSelf Study (JOI22_ho_t2)C++20
10 / 100
45 ms4932 KiB
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
#define l(a, b, i) for (ll i = a; i < b; i++)
#define rl(a, b, i) for (ll i = a; i >= b; i--)
#define vpair vector<pair<ll, ll>>
#define inf LLONG_MAX
#define ninf LLONG_MIN

int main() {
    ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);

    //freopen("selfstudy.inp", "r", stdin);
    //freopen("selfstudy.ans", "w", stdout);

    ll N, M; cin >> N >> M; vector<ll> vecA(N + 1, 0), vecB(N + 1, 0);
    l(1, N + 1, i) cin >> vecA[i];
    l(1, N + 1, i) cin >> vecB[i];

    ll ans = inf;
    l(1, N + 1, i) {
        ll curmax = max(vecA[i], vecB[i]);
        ans = min(ans, curmax);
    }

    cout << ans;
}
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...