#include <bits/stdc++.h>
using namespace std;
template <class T>
T sq(T x) {
  return x * x;
}
const long long inf = 2147383647;
const double pi = 2 * acos(0.0);
const double eps = 1e-9;
const long long maxint = 2147483647;
const long long minint = -2147483648;
long long gcd(long long a, long long b) {
  while (b) {
    a = a % b;
    swap(a, b);
  }
  return a;
}
long long lcm(long long a, long long b) { return (a / gcd(a, b)) * b; }
long long power(long long a, long long p) {
  long long res = 1, x = a;
  while (p) {
    if (p & 1) res = res * x;
    x = x * x;
    p >>= 1;
  }
  return res;
}
long long bigmod(long long a, long long p, long long mod) {
  long long res = 1, x = a;
  while (p) {
    if (p & 1) res = (res * x) % mod;
    x = (x * x) % mod;
    p >>= 1;
  }
  return res;
}
map<long long, int> mp;
int k, x, n, m;
long long arr[100];
bool found;
bool recur(int f1, int l1, int t1, int f2, int l2, int t2) {
  arr[1] = t1;
  arr[2] = t2;
  int i;
  int tf1, tl1, tf2, tl2;
  for (i = 3; i <= k; i++) {
    arr[i] = arr[i - 1] + arr[i - 2];
    if (l1 == 0 && f2 == 2) arr[i]++;
    tf1 = f2;
    tl1 = l2;
    tf2 = f1;
    tl2 = l2;
    f1 = tf1;
    f2 = tf2;
    l1 = tl1;
    l2 = tl2;
    if (arr[i] > x) return false;
  }
  if (arr[k] == x) {
    found = true;
    return true;
  }
  return false;
}
char memo2[3][3][51][3][101][3][51];
bool dp2(int f, int l, int t, int first, int pos, int last, int total) {
  if (memo2[f][l][t][first][pos][last][total]) return false;
  if (pos == m) {
    bool b = recur(f, l, t, first, last, total);
    if (b) {
      memo2[f][l][t][first][pos][last][total] = 2;
      return true;
    }
    memo2[f][l][t][first][pos][last][total] = 1;
    return false;
  }
  int i;
  for (i = 0; i < 3; i++) {
    int nt = 0;
    if (i == 2 && last == 0) nt = 1;
    bool b = dp2(f, l, t, first, pos + 1, i, total + nt);
    if (b) {
      memo2[f][l][t][first][pos][last][total] = 2;
      return true;
    }
  }
  memo2[f][l][t][first][pos][last][total] = 1;
  return false;
}
char memo[3][101][3][51];
bool dp(int first, int pos, int last, int total) {
  if (memo[first][pos][last][total]) return false;
  if (pos == n) {
    int i;
    for (i = 0; i < 3; i++) {
      bool b = dp2(first, last, total, i, 1, i, 0);
      if (b == true) {
        memo[first][pos][last][total] = 2;
        return true;
      }
    }
    memo[first][pos][last][total] = 1;
    return false;
  }
  int i;
  for (i = 0; i < 3; i++) {
    int nt = 0;
    if (i == 2 && last == 0) nt = 1;
    bool b = dp(first, pos + 1, i, total + nt);
    if (b == true) {
      memo[first][pos][last][total] = 2;
      return true;
    }
  }
  memo[first][pos][last][total] = 1;
  return false;
}
vector<int> str1, str2;
void path2(int f, int l, int t, int first, int pos, int last, int total) {
  if (pos == m) {
    return;
  }
  int i;
  for (i = 0; i < 3; i++) {
    int nt = 0;
    if (i == 2 && last == 0) nt = 1;
    int m = memo2[f][l][t][first][pos + 1][i][total + nt];
    if (m == 2) {
      str2.push_back(i);
      path2(f, l, t, first, pos + 1, i, total + nt);
      return;
    }
  }
}
void path(int first, int pos, int last, int total) {
  if (pos == n) {
    int i;
    for (i = 0; i < 3; i++) {
      int m = memo2[first][last][total][i][1][i][0];
      if (m == 2) {
        str2.push_back(i);
        path2(first, last, total, i, 1, i, 0);
        return;
      }
    }
  }
  int i;
  for (i = 0; i < 3; i++) {
    int nt = 0;
    if (i == 2 && last == 0) nt = 1;
    int m = memo[first][pos + 1][i][total + nt];
    if (m == 2) {
      str1.push_back(i);
      path(first, pos + 1, i, total + nt);
      return;
    }
  }
}
int main() {
  scanf("%d %d %d %d", &k, &x, &n, &m);
  found = false;
  int i;
  for (i = 0; i < 3; i++) {
    if (dp(i, 1, i, 0)) break;
  }
  if (found == false) {
    printf("Happy new year!\n");
  } else {
    for (i = 0; i < 3; i++) {
      if (memo[i][1][i][0] == 2) {
        str1.push_back(i);
        path(i, 1, i, 0);
      }
    }
    for (i = 0; i < str1.size(); i++) {
      printf("%c", str1[i] + 'A');
    }
    puts("");
    for (i = 0; i < str2.size(); i++) {
      printf("%c", str2[i] + 'A');
    }
    puts("");
  }
  return 0;
}
