#include <bits/stdc++.h>
template <typename Y>
inline bool updmin(Y &a, Y b) {
  if (a > b) {
    a = b;
    return 1;
  }
  return 0;
}
template <typename Y>
inline bool updmax(Y &a, Y b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template <typename Y>
inline Y abs(Y a) {
  if (a < 0) a = -a;
  return a;
}
template <typename Y>
inline Y sqr(Y a) {
  return a * a;
}
int read() {
  int w = 1, q = 0, ch = ' ';
  for (; ch < '0' || ch > '9'; ch = getchar())
    if (ch == '-') w = -1;
  for (; ch >= '0' && ch <= '9'; ch = getchar()) q = q * 10 + ch - 48;
  return q * w;
}
inline void FileIO() {
  freopen(
      "game"
      ".in",
      "r", stdin);
  freopen(
      "game"
      ".out",
      "w", stdout);
}
const int N = 100010;
std::pair<long long, long long> A[N], B[N], C[N];
int n, m, tp = 0;
int main() {
  n = read(), m = read();
  read(), read();
  long long mx1 = 0, mx2 = 0;
  for (int i = 1; i <= n; i++) {
    A[i].first = read();
    A[i].second = read();
    updmax(mx1, A[i].first);
  }
  for (int i = 1; i <= m; i++) {
    B[i].first = read();
    B[i].second = read();
    updmax(mx2, B[i].first);
  }
  if (mx1 >= mx2) {
    puts("Max");
    return 0;
  }
  std::sort(A + 1, A + 1 + n);
  std::sort(B + 1, B + 1 + m);
  for (int i = 1; i <= m; i++) {
    while (tp >= 1) {
      if (B[i].first >= C[tp - 1].first && B[i].second >= C[tp - 1].second) {
        tp--;
      } else {
        break;
      }
    }
    while (tp >= 2) {
      if ((C[tp - 1].first - C[tp - 2].first) *
              (C[tp - 1].second - B[i].second) <=
          (B[i].first - C[tp - 1].first) *
              (C[tp - 2].second - C[tp - 1].second)) {
        tp--;
      } else {
        break;
      }
    }
    C[tp++] = B[i];
  }
  int tl = -1;
  for (int i = 1; i <= n; i++) {
    while (C[tl + 1].first <= A[i].first) {
      tl++;
    }
    if (!~tl) {
      if (C[0].second <= A[i].second) {
        puts("Max");
        return 0;
      }
    } else {
      if (A[i].first * (C[tl].second - C[tl + 1].second) +
              A[i].second * (C[tl + 1].first - C[tl].first) >=
          -C[tl].first * C[tl + 1].second + C[tl].second * C[tl + 1].first) {
        puts("Max");
        return 0;
      }
    }
  }
  puts("Min");
  return 0;
}
