#include <bits/stdc++.h>
using namespace std;
long long int gcd(long long int a, long long int b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
signed main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  long long int a, b;
  cin >> a >> b;
  long long int lcm = (a * b) / gcd(a, b);
  long long int sa = 0, sb = 0;
  sa = (lcm / a) - 1;
  sb = (lcm / b) - 1;
  if (a > b)
    sa++;
  else
    sb++;
  if (sa == sb)
    cout << "Equal"
         << "\n";
  else if (sa > sb)
    cout << "Dasha"
         << "\n";
  else
    cout << "Masha"
         << "\n";
  return 0;
}
