#include <bits/stdc++.h>
int main(){
std::vector<int> idoh, idov;
int korok, cache;
int v = 0, h = 0;
int vmin = 1000000, hmin = 1000000;
std::cin >> korok;
for(int i = 0; i < korok; i++) {
std::cin >> cache;
idoh.push_back(cache);
h += idoh[i];
if (hmin > idoh[i]) {hmin = idoh[i];}
}
for(int i = 0; i < korok; i++) {
std::cin >> cache;
idov.push_back(cache);
v += idov[i];
if (vmin > idov[i]) {vmin = idov[i];}
}
if (v < h) {std::cout << "Verstappen\n";}
else {std::cout << "Hamilton\n";}
if (vmin < hmin) {std::cout << "Verstappen";}
else {std::cout << "Hamilton";}
std::cin >> h;
}
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 3ms | 2088 KiB | ||||
2 | Accepted | 3ms | 2140 KiB | ||||
subtask2 | 10/10 | ||||||
3 | Accepted | 3ms | 2292 KiB | ||||
4 | Accepted | 3ms | 2508 KiB | ||||
5 | Accepted | 3ms | 2752 KiB | ||||
6 | Accepted | 2ms | 2820 KiB | ||||
subtask3 | 15/15 | ||||||
7 | Accepted | 2ms | 2740 KiB | ||||
8 | Accepted | 3ms | 2836 KiB | ||||
9 | Accepted | 3ms | 3076 KiB | ||||
10 | Accepted | 3ms | 3324 KiB | ||||
11 | Accepted | 3ms | 3504 KiB | ||||
subtask4 | 20/20 | ||||||
12 | Accepted | 2ms | 3512 KiB | ||||
13 | Accepted | 2ms | 3640 KiB | ||||
14 | Accepted | 2ms | 3720 KiB | ||||
15 | Accepted | 3ms | 3852 KiB | ||||
16 | Accepted | 3ms | 4092 KiB | ||||
17 | Accepted | 3ms | 4268 KiB | ||||
18 | Accepted | 2ms | 4396 KiB | ||||
19 | Accepted | 2ms | 4392 KiB | ||||
subtask5 | 55/55 | ||||||
20 | Accepted | 3ms | 4488 KiB | ||||
21 | Accepted | 3ms | 4572 KiB | ||||
22 | Accepted | 3ms | 4572 KiB | ||||
23 | Accepted | 3ms | 4700 KiB | ||||
24 | Accepted | 3ms | 4568 KiB | ||||
25 | Accepted | 3ms | 4564 KiB | ||||
26 | Accepted | 3ms | 4564 KiB | ||||
27 | Accepted | 3ms | 4540 KiB | ||||
28 | Accepted | 3ms | 4648 KiB |