#include <bits/stdc++.h>
using namespace std;
const int INF = 2000000000;
const int MOD = 1000000007;
vector<string> answer;
long long int n;
void dfs(int x, string s) {
  if (x == n) {
    answer.push_back(s);
  } else {
    char cs = s.at(s.size() - 1);
    int num = cs - 'a';
    for (int i = 0; i < num + 1; i++) {
      char ad = 'a' + i;
      dfs(x + 1, s + ad);
    }
  }
}
int main() {
  n = 2;
  dfs(1, "a");
  for (int i = 0; i < answer.size(); i++) {
    cout << answer.at(i) << endl;
  }
}
