#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 10;
inline long long operator^(pair<long long, long long> a,
                           pair<long long, long long> b) {
  return a.first * b.second - a.second * b.first;
}
inline pair<long long, long long> operator-(pair<long long, long long> a,
                                            pair<long long, long long> b) {
  return pair<long long, long long>(a.first - b.first, a.second - b.second);
}
pair<long long, long long> s[N], tp;
int T;
set<pair<long long, long long> > Max;
vector<pair<long long, long long> > v;
int n, m;
long long first, second, mx, my, X, Y;
int main() {
  cin >> n >> m >> first >> second;
  for (int i = 1; i <= n; i++)
    cin >> tp.first >> tp.second, mx = max(mx, tp.first),
                                  my = max(my, tp.second), v.push_back(tp),
                                  Max.insert(tp);
  for (int i = 1; i <= m; i++)
    cin >> tp.first >> tp.second, X = max(X, tp.first), Y = max(Y, tp.second),
                                  v.push_back(tp);
  if (mx >= X || my >= Y) return puts("Max"), 0;
  mx = max(mx, X);
  my = max(my, Y);
  v.push_back(pair<long long, long long>(0, my));
  v.push_back(pair<long long, long long>(mx, 0));
  sort(v.begin(), v.end());
  v.erase(unique(v.begin(), v.end()), v.end());
  s[++T] = v[0];
  for (int i = 1; i < v.size(); i++) {
    while (T >= 2 && ((s[T] - s[T - 1]) ^ (v[i] - s[T - 1])) > 0) T--;
    s[++T] = v[i];
  }
  for (int i = 1; i <= T; i++)
    if (Max.count(s[i])) return puts("Max"), 0;
  puts("Min");
  return 0;
}
