#include using namespace std; int main(){ int x, n, m; int i; int a[200000], b[200000]; bool isa = false, isb = false; cin >> x >> n >> m; for(i = 0; i < n; i++){ cin >> a[i]; if(x == a[i]){ isa = true; } } for(i = 0; i < m; i++){ cin >> b[i]; if(x == b[i]){ isb = true; } } if(isa){ if(isb){ cout << "MrMaxValu" << endl; }else{ cout << "MrMax" << endl; } }else{ if(isb){ cout << "MaxValu" << endl; }else{ cout << -1 << endl; } } return 0; }