#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 2;
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
long long lcm(long long a, long long b) { return a * (b / gcd(a, b)); }
void solve() {
  long long a, b;
  long long n = 1e18;
  cin >> a >> b;
  long long dasha = n / a;
  long long masha = n / b;
  long long both = n / lcm(a, b);
  if (a > b)
    masha -= both;
  else
    dasha -= both;
  if (abs(dasha - masha) <= 1) {
    cout << "Equal\n";
    return;
  }
  if (dasha > masha)
    cout << "Dasha\n";
  else if (masha > dasha)
    cout << "Masha\n";
  else
    cout << "Equal\n";
}
int main(void) {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int tc = 1;
  while (tc--) solve();
}
