#include "bits/stdc++.h"
#include <atcoder/all>
using namespace std;
using namespace atcoder;
using ll = long long;
#define rep(i, n) for (long long int i = 0; i < (long long int)(n); i++)
long long int MOD = 998244353;
int main(){
    deque<char> q[4];
    ll k;
    cin >> k;
    q[0].push_back('A');
    q[0].push_back('E');
    q[1].push_back('B');
    q[2].push_back('C');
    q[3].push_back('D');
    rep(i,k){
        ll a,b;
        a = i % 4;
        b = (i+1) % 4;
        char c;
        c = q[a].front();
        q[a].pop_front();
        q[b].push_back(c);
    }
    rep(i,4){
        while(q[i].size()){
            cout << q[i].front();
            q[i].pop_front();
        }
        cout <<endl;
    }
}