#include <bits/stdc++.h>
using namespace std;
const int MX = 2e5 + 5, MXX = 23;
const long long mod = 1e9 + 7;
string s, ans[2] = {"Mike", "Ann"};
int pr[35], t;
int id(char c) { return (int(c) - int('a')); }
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> s;
  cout << ans[0] << endl;
  for (int i = id(s[0]) + 1; i < 30; ++i) pr[i] = 1;
  for (int i = 1; i < s.size(); ++i) {
    t = id(s[i]);
    if (pr[t]) {
      cout << ans[1] << endl;
      continue;
    }
    cout << ans[0] << endl;
    for (int ce = t + 1; ce < 30; ++ce) pr[ce] = 1;
  }
  return 0;
}
