#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string s(n, 'a');
  cout << s << endl;
  string t(s);
  for (size_t i = 0; i < t.size(); i++) {
    t[i] += i;
  }
  while (s != t) {
    for (size_t i = s.size() - 1; i >= 0; i--) {
      if (s[i] != t[i]) {
        s[i]++;
        break;
      }
      s[i] = 'a';
    }
    cout << s << endl;
  }
  return 0;
}
