#include <bits/stdc++.h>
using namespace std;
int n, m, x, y;
struct Point {
  int x, y;
  Point(int x = 0, int y = 0) : x(x), y(y) {}
  bool operator<(Point const &ano) const {
    return x != ano.x ? x < ano.x : y < ano.y;
  }
} Min[100010], Max[100010];
Point operator+(Point a, Point b) { return Point(a.x + b.x, a.y + b.y); }
Point operator-(Point a, Point b) { return Point(a.x - b.x, a.y - b.y); }
long long det(Point a, Point b) {
  return (long long)a.x * b.y - (long long)a.y * b.x;
}
int get_up(Point *map, int n) {
  int m = 0;
  for (int i = 1; i <= n; ++i) {
    for (; m > 1 && det(map[i] - map[m - 1], map[m] - map[m - 1]) <= 0; --m)
      ;
    map[++m] = map[i];
  }
  return m;
}
void halt() {
  printf("Max\n");
  exit(0);
}
int ok(Point p, Point a, Point b) {
  if (p.y >= a.y) return 0;
  return det(a - b, p - b) > 0;
}
int main() {
  scanf("%d%d", &n, &m);
  scanf("%d%d", &x, &y);
  for (int i = 1; i <= n; ++i) scanf("%d%d", &Max[i].x, &Max[i].y);
  for (int i = 1; i <= m; ++i) scanf("%d%d", &Min[i].x, &Min[i].y);
  sort(Min + 1, Min + m + 1);
  int t = 0;
  for (int i = 1; i <= m; ++i) {
    for (; t && Min[i].y >= Min[t].y; --t)
      ;
    Min[++t] = Min[i];
  }
  m = get_up(Min, t);
  sort(Max + 1, Max + n + 1);
  int p = 1;
  for (int i = 1; i <= n; ++i) {
    if (m == 1) {
      if (!(Max[i].x < Min[1].x && Max[i].y < Min[1].y)) halt();
      continue;
    }
    for (; p + 1 <= m && Min[p + 1].x <= Max[i].x; ++p)
      ;
    if (!ok(Max[i], Min[p], Min[p + 1])) halt();
  }
  printf("Min\n");
  return 0;
}
