func_code_string: #include <bits/stdc++.h>   using namespace std;   template <class T>   using min_heap = priority_queue<T, vector<T>, greater<T>>;   template <class T, class U>   inline void MAX(T &a, U b) {     if (a < b) a = b;   }   template <class T, class U>   inline void MIN(T &a, U b) {     if (a > b) a = b;   }   template <class T, class U>   inline bool ckmax(T &a, U b) {     return b > a && (a = b, true);   }   template <class T, class U>   inline bool ckmin(T &a, U b) {     return b < a && (a = b, true);   }   template <class T, class U>   inline bool INR(T i, U l, U r) {     return l <= i && i <= r;   }   const int MOD = (int)(1e9) + 7;   const int INF = 0x3f3f3f3f;   const int NINF = -0x3f3f3f40;   const long long INF_L = 0x3f3f3f3f3f3f3f3f;   const long long NINF_L = -0x3f3f3f3f3f3f3f40;   const int MAXN = 100010;   char arr[]{ A ,  C ,  Z };   bool res(int n, int i1, int j1, string &s1) {     int acc = 0;     for (int i = 1; i < n; i++) {       if (i == n - 1)         s1 += arr[i1 % 3];       else if (acc == j1)         s1 +=  Z ;       else         s1 += (s1[((int)(s1).size()) - 1] ==  C  ?  A  :  C );       if (s1[i - 1] ==  A  && s1[i] ==  C ) acc++;     }     return acc == j1;   }   int main() {     ios::sync_with_stdio(0);     cin.tie(0);     cout.tie(0);     cout.precision(20);     int k, x, n, m;     cin >> k >> x >> n >> m;     for (int i1 = 0; i1 < 9; i1++) {       for (int j1 = 0; j1 <= n / 2; j1++) {         for (int i2 = 0; i2 < 9; i2++) {           for (int j2 = 0; j2 <= m / 2; j2++) {             if (n == 1 && (i1 % 4 != 0) || m == 1 && (i2 % 4 != 0)) continue;             pair<int, int> n1, n2;             n1.first = i1, n1.second = j1;             n2.first = i2, n2.second = j2;             bool bad = false;             for (int a = 0; a <= k - 3; a++) {               pair<int, int> n3;               n3.first = (n1.first / 3) * 3 + (n2.first % 3);               n3.second = n1.second + n2.second;               if (n1.first % 3 == 0 && n2.first / 3 == 1) n3.second++;               if (n3.second > x) {                 bad = true;                 break;               }               n1 = n2, n2 = n3;             }             if (bad) continue;             if (n2.second == x) {               string s1 =   , s2 =   ;               s1 += arr[i1 / 3];               if (n != 1) {                 if (!res(n, i1, j1, s1)) {                   continue;                 }               }               s2 += arr[i2 / 3];               if (m != 1) {                 if (!res(m, i2, j2, s2)) {                   continue;                 }               }               cout << s1 <<   n  << s2 <<   n ;               return 0;             }           }         }       }     }     cout <<  Happy new year!  <<   n ;   }   