#include <bits/stdc++.h>
using namespace std;
char str[3][20] = {"Stas", "Missing", "Masha"};
int f[31700][32], a, b, n;
int dp(int a, int b) {
  if (f[a][b] != -1) return f[a][b];
  if (a == 1 && 1 << b >= n) return 1;
  if (b == 1 && a * a >= n) return n - a & 1 ? 0 : 2;
  if (pow(a, b) + 1e-6 > n) return f[a][b] = 2;
  return f[a][b] = 2 - min(dp(a + 1, b), dp(a, b + 1));
}
int main() {
  memset(f, -1, sizeof(f));
  scanf("%d%d%d", &a, &b, &n);
  printf("%s\n", str[dp(a, b)]);
  return 0;
}
