#include <bits/stdc++.h>
using namespace std;
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long lcm(long long a, long long b) { return a * b / gcd(a, b); }
int main() {
  long long a, b;
  scanf("%lld", &a);
  ;
  scanf("%lld", &b);
  ;
  long long x = lcm(a, b);
  int t1 = x / a;
  --t1;
  int t2 = x / b;
  --t2;
  if (a < b)
    ++t2;
  else
    ++t1;
  if (t1 == t2) {
    cout << "Equal" << endl;
  } else if (t1 > t2) {
    cout << "Dasha" << endl;
  } else {
    cout << "Masha" << endl;
  }
  return 0;
}
