#include <bits/stdc++.h>
using namespace std;
const int mod = 998244353;
int Mod(int x) { return x >= mod ? x - mod : x; }
long long read() {
  long long x = 0;
  int f = 1;
  char ch = getchar();
  for (; !isdigit(ch); ch = getchar())
    if (ch == '-') f = -1;
  for (; isdigit(ch); ch = getchar()) x = x * 10 + (ch ^ 48);
  return x * f;
}
void print(long long x) {
  if (x < 0) putchar('-'), x = -x;
  if (x > 9) print(x / 10);
  putchar(x % 10 + '0');
}
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
int main() {
  long long a = read(), b = read(), c, n, m;
  c = gcd(a, b);
  long long res = a * b / c - 1;
  n = res / a, m = res / b;
  if (n > m)
    m++;
  else if (n < m)
    n++;
  else {
    puts("Equal");
    return 0;
  }
  if (n > m)
    puts("Dasha");
  else if (n == m)
    puts("Equal");
  else
    puts("Masha");
}
