#include <bits/stdc++.h>
using namespace std;
long long d, m, Vd[1000047], Vm[1000047];
int main() {
  cin >> d >> m;
  for (long long i = 0; i <= m; i++) Vd[i] = d * i;
  for (long long i = 0; i <= d; i++) Vm[i] = m * i;
  long long minute = 0, l = 0, r = 0;
  long long dasha = 0, masha = 0;
  while (minute < m * d) {
    if (Vd[l] < Vm[r])
      dasha += Vd[l] - minute, minute = Vd[l++];
    else if (Vd[l] > Vm[r])
      masha += Vm[r] - minute, minute = Vm[r++];
    else if (d > m)
      dasha += Vd[l] - minute, minute = Vd[l++], r++;
    else
      masha += Vm[r] - minute, minute = Vm[r++], l++;
  }
  if (dasha > masha) cout << "Dasha" << endl;
  if (dasha < masha) cout << "Masha" << endl;
  if (dasha == masha) cout << "Equal" << endl;
  return 0;
}
