#include <bits/stdc++.h>
using namespace std;
long long int i, n, m, x, y, z, j, k, l, mn = LLONG_MAX, mx = 0, c, a[200005],
                                         r, cnt = 0, sum = 0;
string str;
char ch;
set<long long int> second;
map<long long int, long long int> mp;
vector<vector<long long int>> g;
vector<long long int> v;
char grid[60][60];
long long int d[60][60];
bool vis[60][60];
long long int dx[] = {0, 1, 0, -1, 1, -1, -1, 1};
long long int dy[] = {1, 0, -1, 0, 1, -1, 1, -1};
bool valid(long long int x, long long int y) {
  return (x >= 0 && y >= 0 && y < m && x < n);
}
long long int gcd(long long int x, long long int y) {
  if (y == 0) return x;
  return gcd(y, x % y);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  cin >> n >> m;
  long long int dasha = 0, masha = 0;
  k = gcd(n, m);
  long long int lcm = (n * m) / k;
  dasha = lcm / n - 1;
  masha = lcm / m - 1;
  dasha > masha ? masha++ : dasha++;
  if (dasha == masha)
    cout << "Equal";
  else if (dasha > masha)
    cout << "Dasha";
  else
    cout << "Masha";
  return 0;
}
