#include <bits/stdc++.h>
using namespace std;
ifstream in;
ofstream out;
const long long kk = 1000;
const long long ml = kk * kk;
const long long mod = ml * kk + 7;
;
const long long inf = ml * ml * ml + 7;
long long n, t, a, b;
vector<long long> m;
vector<long long> tp;
bool viv = false;
void check(string s) {
  cout << s << endl;
  long long res;
  cin >> res;
  m.push_back(res);
  if (res == 0 || res == -1) exit(0);
}
void solve() {
  check("a");
  n = m.back();
  string s;
  for (long long i = 0; i < n; i++) s += 'b';
  check(s);
  a = m.back();
  n++;
  s += 'b';
  vector<long long> pl;
  for (long long i = 0; i < n - 1; i++) {
    s[i] = 'a';
    check(s);
    if (m.back() < a) pl.push_back(i);
    s[i] = 'b';
  }
  if (pl.size() < a) pl.push_back(n - 1);
  for (auto i : pl) s[i] = 'a';
  check(s);
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long t = 1;
  while (t--) solve();
  return 0;
}
