#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  cin >> N;
  for (int S = 0; S < (1 << (N - 1)); ++S) {
    string ans = "a";
    for (int i = N - 2; i >= 0; --i) {
      if ((S >> i) & 1)
        ans += "b";
      else
        ans += "a";
    }
    cout << ans << endl;
  }
}
