#include <bits/stdc++.h>
using namespace std;
vector<int> l;
int f[4];
int n, m;
int main() {
  for (int i = 0; i < 4; i++) {
    cin >> f[i];
    if (l.size() < 2) {
      if (f[i]) {
        l.push_back(i);
        f[i]--;
      }
    }
  }
  if (l.size() + f[0] + f[1] + f[2] + f[3] == 1) {
    cout << "1 1" << endl;
    cout << (char)(l[0] + 'A') << endl;
    return 0;
  }
  int u = l[0];
  int d = l[1];
  cout << 50 << " " << 50 << endl;
  for (int i = 1; i <= 24; i += 2) {
    for (int j = 1; j <= 50; j += 2) {
      int sw = 0;
      for (int k = 0; k < 4; k++)
        if (k != u && sw == 0) {
          if (f[k]) {
            cout << (char)(k + 'A');
            sw = 1;
            f[k]--;
            break;
          }
        }
      if (sw == 0) {
        cout << (char)(u + 'A');
      }
      cout << (char)(u + 'A');
    }
    cout << endl;
    for (int j = 1; j <= 50; j++) {
      cout << (char)(u + 'A');
    }
    cout << endl;
  }
  for (int j = 1; j <= 50; j++) {
    cout << (char)(d + 'A');
  }
  cout << endl;
  for (int j = 1; j <= 50; j++) {
    cout << (char)(d + 'A');
  }
  cout << endl;
  for (int i = 27; i <= 50; i += 2) {
    for (int j = 1; j <= 50; j += 2) {
      int sw = 0;
      for (int k = 0; k < 4; k++)
        if (k != d && sw == 0) {
          if (f[k]) {
            cout << (char)(k + 'A');
            sw = 1;
            f[k]--;
            break;
          }
        }
      if (sw == 0) {
        cout << (char)(d + 'A');
      }
      cout << (char)(d + 'A');
    }
    cout << endl;
    for (int j = 1; j <= 50; j++) {
      cout << (char)(d + 'A');
    }
    cout << endl;
  }
}
