#include #include using namespace std; void next_string(string &s){ if (s[3] < 'z'){ ++s[3]; return; }else{ s[3] = 'a'; } if (s[2] < 'z'){ ++s[2]; return ; }else{ s[2] = 'a'; } if (s[1] < 'z'){ ++s[1]; return ; }else{ s[1] = 'a'; } if (s[0] < 'z'){ ++s[0]; return ; }else{ s[1] = 'a'; cout << "overflow" << endl; } return; } int main() { cin.tie(0); ios::sync_with_stdio(false); int n; cin >> n; string s = "aaaa"; for (int i = 1; i < n; ++i){ cout << 'a' << s << 'a' << '\n'; next_string(s); } cout << "an" << endl; return 0; }