#include <bits/stdc++.h>
using namespace std;
int a, b, d;
int gcd(int a, int b) {
  int i, j;
  i = a;
  j = b;
  int t;
  if (i > j) {
    t = i;
    i = j;
    j = t;
  }
  while (j % i > 0) {
    t = j % i;
    j = i;
    i = t;
  }
  return i;
}
int main() {
  scanf("%d %d", &a, &b);
  d = gcd(a, b);
  if (a / d - b / d == 1 || b / d - a / d == 1)
    printf("Equal\n");
  else if (a > b)
    printf("Masha\n");
  else
    printf("Dasha\n");
  return 0;
}
