#include <bits/stdc++.h>
using namespace std;
int k, num, n, m;
struct Node {
  int x, l, r;
  Node(int _x = 0, int _l = 0, int _r = 0) { x = _x, l = _l, r = _r; }
} a[11], b[11], f[55];
int ra[105], rb[105];
inline int calc(int l, int r, int n) { return (n - (l != 0) - (r != 2)) / 2; }
inline void print(int x, int y, int k1, int k2) {
  ra[1] = a[x].l, ra[n] = a[x].r;
  rb[1] = b[y].l, rb[m] = b[y].r;
  for (int i = 2; i < n; ++i) {
    if (k1 > 0) {
      if (ra[i - 1] == 0)
        ra[i] = 2, --k1;
      else
        ra[i] = 0;
    } else
      ra[i] = 1;
  }
  for (int i = 2; i < m; ++i) {
    if (k2 > 0) {
      if (rb[i - 1] == 0)
        rb[i] = 2, --k2;
      else
        rb[i] = 0;
    } else
      rb[i] = 1;
  }
  for (int i = 1; i <= n; ++i) printf("%c", 'A' + ra[i]);
  printf("\n");
  for (int i = 1; i <= m; ++i) printf("%c", 'A' + rb[i]);
  printf("\n");
}
inline void work() {
  int tn = 0, tm = 0;
  for (int i = 0; i <= 2; ++i) {
    if (n == 1) {
      a[++tn] = Node(0, i, i);
    } else {
      for (int j = 0; j <= 2; ++j) a[++tn] = Node(calc(i, j, n), i, j);
    }
    if (m == 1) {
      b[++tm] = Node(0, i, i);
    } else {
      for (int j = 0; j <= 2; ++j) b[++tm] = Node(calc(i, j, m), i, j);
    }
  }
  for (int i = 1; i <= tn; ++i)
    for (int j = 1; j <= tm; ++j) {
      f[1] = a[i];
      f[2] = b[j];
      for (f[1].x = 0; f[1].x <= a[i].x; ++f[1].x)
        for (f[2].x = 0; f[2].x <= b[j].x; ++f[2].x) {
          for (int z = 3; z <= k; ++z) {
            f[z].x =
                f[z - 1].x + f[z - 2].x + (f[z - 2].r == 0 && f[z - 1].l == 2);
            f[z].l = f[z - 2].l;
            f[z].r = f[z - 1].r;
            if (f[z].x > num) f[z].x = num + 1;
          }
          if (f[k].x == num) {
            print(i, j, f[1].x, f[2].x);
            return;
          }
        }
    }
  printf("Happy new year!\n");
}
int main() {
  scanf("%d %d %d %d", &k, &num, &n, &m);
  work();
  return 0;
}
