#include <bits/stdc++.h>
using namespace std;
using LL = long long;
int main() {
  ios::sync_with_stdio(false);
  int n;
  cout << "a" << endl;
  cin >> n;
  if (n == 0) return 0;
  string s;
  for (int i = 0; i < n; ++i) s.push_back('b');
  cout << s << endl;
  int base;
  cin >> base;
  if (base == 0) return 0;
  s = "b" + s;
  ++n;
  for (int i = 0; i < n; ++i) {
    s[i] = 'a';
    cout << s << endl;
    int now;
    cin >> now;
    if (now == 0) return 0;
    if (now > base) {
      s[i] = 'b';
    } else if (now < base) {
      base = now;
    }
  }
  return 0;
}
