#include <bits/stdc++.h>
char m[51][51];
int a, b, c, d;
int main() {
  scanf("%d%d%d%d", &a, &b, &c, &d);
  a--, b--, c--, d--;
  for (int i = 1; i <= 50; i++) {
    for (int j = 1; j <= 50; j++) {
      if (i <= 25 && j <= 25)
        m[i][j] = 'A';
      else if (i <= 25 && j > 25)
        m[i][j] = 'B';
      else if (i > 25 && j <= 25)
        m[i][j] = 'C';
      else
        m[i][j] = 'D';
    }
  }
  puts("50 50");
  for (int i = 2; i <= 25; i += 2)
    for (int j = 2; j <= 25; j += 2)
      if (b) m[i][j] = 'B', b--;
  for (int i = 2; i <= 25; i += 2)
    for (int j = 27; j <= 50; j += 2)
      if (c) m[i][j] = 'C', c--;
  for (int i = 27; i <= 50; i += 2)
    for (int j = 2; j <= 25; j += 2)
      if (d) m[i][j] = 'D', d--;
  for (int i = 27; i <= 50; i += 2)
    for (int j = 27; j <= 50; j += 2)
      if (a) m[i][j] = 'A', a--;
  for (int i = 1; i <= 50; i++) printf("%s\n", m[i] + 1);
  return 0;
}
