#include <bits/stdc++.h>
using namespace std;
set<pair<int, int> > s0, s;
int K;
long long xx[200010], yy[200010];
void func(long long x, long long y) {
  while (K > 0 && yy[K - 1] < y) K--;
  while (K >= 2) {
    long long tmp = (x - xx[K - 2]) * (yy[K - 1] - yy[K - 2]) -
                    (xx[K - 1] - xx[K - 2]) * (y - yy[K - 2]);
    if (tmp < 0)
      K--;
    else
      break;
  }
  xx[K] = x;
  yy[K] = y;
  K++;
}
int main(void) {
  int N, M, x, y, i;
  cin >> N >> M >> x >> y;
  for ((i) = 0; (i) < (int)(N); (i)++) {
    scanf("%d%d", &x, &y);
    s0.insert(make_pair(x, y));
    s.insert(make_pair(x, -y));
  }
  for ((i) = 0; (i) < (int)(M); (i)++) {
    scanf("%d%d", &x, &y);
    s.insert(make_pair(x, -y));
  }
  for (__typeof((s).begin()) itr = (s).begin(); itr != (s).end(); itr++) {
    x = (*itr).first;
    y = (*itr).second;
    func(x, -y);
  }
  int tp;
  string ans = "Min";
  for ((i) = 0; (i) < (int)(K); (i)++) {
    if (s0.find(make_pair(xx[i], yy[i])) != s0.end()) ans = "Max";
  }
  cout << ans << endl;
  return 0;
}
