#include <bits/stdc++.h>
using namespace std;
long long gcd(long long a, long long b) { return b == 0 ? a : gcd(b, a % b); }
const int MAXN = 100000;
typedef struct P {
  int x, y;
  P() {}
  P(int x, int y) : x(x), y(y) {}
} P;
bool operator<(const P &a, const P &b) {
  if (a.x != b.x) return a.x < b.x;
  return a.y > b.y;
}
P operator-(const P &a, const P &b) { return P(a.x - b.x, a.y - b.y); }
long long operator^(const P &a, const P &b) {
  return (long long)a.x * b.y - (long long)a.y * b.x;
}
int side(const P &a, const P &b, const P &c) {
  long long ret = (b - a) ^ (c - a);
  return ret < 0 ? -1 : ret > 0 ? +1 : 0;
}
void makehull(int &n, P p[MAXN + 2]) {
  sort(p, p + n);
  int nh = 0;
  for (int i = (0); i < (n); ++i) {
    while (nh >= 2 && side(p[nh - 2], p[nh - 1], p[i]) >= 0) --nh;
    p[nh++] = p[i];
  }
  n = nh;
}
int n[2];
P s;
P p[2][MAXN + 2];
void run() {
  for (int i = (0); i < (2); ++i) scanf("%d", &n[i]);
  scanf("%d%d", &s.x, &s.y);
  for (int i = (0); i < (2); ++i)
    for (int j = (0); j < (n[i]); ++j) scanf("%d%d", &p[i][j].x, &p[i][j].y);
  for (int i = (0); i < (2); ++i) {
    int hx = p[i][0].x;
    for (int j = (1); j < (n[i]); ++j)
      if (p[i][j].x > hx) hx = p[i][j].x;
    p[i][n[i]].x = hx, p[i][n[i]].y = 0, ++n[i];
  }
  for (int i = (0); i < (2); ++i) {
    int hy = p[i][0].y;
    for (int j = (1); j < (n[i]); ++j)
      if (p[i][j].y > hy) hy = p[i][j].y;
    p[i][n[i]].x = 0, p[i][n[i]].y = hy, ++n[i];
  }
  for (int i = (0); i < (2); ++i) makehull(n[i], p[i]);
  int j = 0;
  for (int i = (0); i < (n[0]); ++i) {
    while (j + 2 < n[1] && p[1][j + 1] < p[0][i]) ++j;
    if (side(p[1][j], p[0][i], p[1][j + 1]) <= 0) {
      printf("Max\n");
      return;
    }
  }
  printf("Min\n");
}
int main() {
  run();
  return 0;
}
