#include <iostream>
using namespace std;
int main(){
cin.tie(0); ios_base::sync_with_stdio(false);
int n; int h=0; int hm=1e9; int f=0; int fm=1e9; cin >> n;
for(int i=0; i<n; i++){int x; cin >> x; h+=x; hm=min(x,hm);}
for(int i=0; i<n; i++){int x; cin >> x; f+=x; fm=min(x,fm);}
if(h<f) cout << "Hamilton\n"; else cout << "Verstappen\n";
if(hm<fm) cout << "Hamilton\n"; else cout << "Verstappen\n";
}
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 3ms | 2172 KiB | ||||
2 | Accepted | 3ms | 2168 KiB | ||||
subtask2 | 10/10 | ||||||
3 | Accepted | 3ms | 2380 KiB | ||||
4 | Accepted | 3ms | 2616 KiB | ||||
5 | Accepted | 2ms | 2680 KiB | ||||
6 | Accepted | 3ms | 2752 KiB | ||||
subtask3 | 15/15 | ||||||
7 | Accepted | 2ms | 2828 KiB | ||||
8 | Accepted | 3ms | 3060 KiB | ||||
9 | Accepted | 2ms | 3152 KiB | ||||
10 | Accepted | 2ms | 3048 KiB | ||||
11 | Accepted | 2ms | 3056 KiB | ||||
subtask4 | 20/20 | ||||||
12 | Accepted | 2ms | 3044 KiB | ||||
13 | Accepted | 2ms | 3044 KiB | ||||
14 | Accepted | 3ms | 3172 KiB | ||||
15 | Accepted | 2ms | 3252 KiB | ||||
16 | Accepted | 3ms | 3476 KiB | ||||
17 | Accepted | 2ms | 3488 KiB | ||||
18 | Accepted | 3ms | 3700 KiB | ||||
19 | Accepted | 2ms | 3684 KiB | ||||
subtask5 | 55/55 | ||||||
20 | Accepted | 2ms | 3792 KiB | ||||
21 | Accepted | 3ms | 3936 KiB | ||||
22 | Accepted | 3ms | 3884 KiB | ||||
23 | Accepted | 2ms | 3968 KiB | ||||
24 | Accepted | 3ms | 4204 KiB | ||||
25 | Accepted | 2ms | 4280 KiB | ||||
26 | Accepted | 2ms | 4168 KiB | ||||
27 | Accepted | 3ms | 4404 KiB | ||||
28 | Accepted | 2ms | 4500 KiB |