#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  string a;
  cin >> a;
  long long n = a.size();
  vector<set<long long> > pos(26);
  for (long long i = 0; i < n; i++) {
    pos[a[i] - 'a'].insert(i);
  }
  vector<long long> lp(n, INT_MAX);
  for (long long i = 1; i < n; i++) {
    for (long long j = 0; j < (a[i] - 'a'); j++) {
      lp[i] = min(lp[i], *(pos[j].begin()));
    }
  }
  for (long long k = 0; k < n; k++) {
    if (lp[k] == INT_MAX || lp[k] >= k) {
      cout << "Mike\n";
    } else {
      cout << "Ann\n";
    }
  }
  return 0;
}
