#include using namespace std; int main() { cin.tie(nullptr); ios::sync_with_stdio(false); int N; cin >> N; if(N <= 2) { cout << "-1\n"; return 0; } N *= 2; for(int i = 0; i < N; i++) { for(int j = 0; j < N; j++) { if(i == 0) { cout << "A"; } else if(j == N - 1) { cout << "A"; } else if(i <= N / 2) { cout << "B"; } else if(i == N / 2 + 1) { if(j < N / 2 - 1) { cout << "A"; } else { cout << "B"; } } else { cout << "A"; } } cout << "\n"; } return 0; }