#include #include #include #include #include #include #include #include #include #include using namespace std; struct aaa{aaa(){cin.tie(nullptr); ios::sync_with_stdio(false); cout<ostream &operator<<(ostream &o,const vector&v){o<<"{";for(int i=0;i<(int)v.size();i++)o<<(i>0?", ":"")<> x >> n >> m; vector a(n); vector b(m); for (int i=0; i> a[i]; for (int i=0; i> b[i]; sort(a.begin(), a.end()); sort(b.begin(), b.end()); auto it1 = lower_bound(a.begin(), a.end(), x); auto it2 = lower_bound(b.begin(), b.end(), x); if (it1 == a.end()) it1--; if (it2 == b.end()) it2--; if (*it1 == x && *it2 == x) { cout << "MrMaxValu" << endl; } else if (*it1 == x) { cout << "MrMax" << endl; } else if (*it2 == x) { cout << "MaxValu" << endl; } else { cout << -1 << endl; } }