#include <bits/stdc++.h>
using namespace std;
void swap(int *a, int *b) {
  int c = *a;
  *a = *b;
  *b = c;
}
int main() {
  int a, b;
  cin >> a >> b;
  int x = a, y = b;
  while (x != 0 && y != 0) {
    x %= y;
    swap(&x, &y);
  }
  a /= x;
  b /= x;
  if (abs(a - b) <= 1) {
    cout << "Equal";
  } else if (a < b)
    cout << "Dasha";
  else
    cout << "Masha";
  return 0;
}
