#include <bits/stdc++.h>
using namespace std;
template <class T>
bool chmax(T &a, const T &b) {
  if (a < b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
bool chmin(T &a, const T &b) {
  if (b < a) {
    a = b;
    return true;
  }
  return false;
}
const long long INF =
    sizeof(long long) == sizeof(long long) ? 0x3f3f3f3f3f3f3f3fLL : 0x3f3f3f3f;
const long long MOD = (long long)1e9 + 7;
const double EPS = 1e-9;
signed main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  long long N;
  cin >> N;
  for (long long i = (0), i_len = (1 << (N - 1)); i < i_len; i++) {
    string res;
    for (long long j = (0), j_len = (N - 1); j < j_len; j++) {
      if ((i >> j) & 1) {
        res += 'b';
      } else {
        res += 'a';
      }
    }
    res += 'a';
    reverse(begin(res), end(res));
    cout << res << endl;
  }
  return 0;
}
