#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  while (b) {
    int tmp = a % b;
    a = b;
    b = tmp;
  }
  return a;
}
int main() {
  int a, b;
  cin >> a >> b;
  int k = gcd(a, b);
  if (abs(a / k - b / k) <= 1)
    cout << "Equal\n";
  else if (a < b)
    cout << "Dasha\n";
  else
    cout << "Masha\n";
  return 0;
}
