#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string s, t;
  string st1, st2, st3;
  cin >> s >> t;
  if (s[0] != s[1] && t[0] != t[1]) {
    for (int i = 1; i <= n; i++) {
      st1 += 'a';
    }
    for (int i = 1; i <= n; i++) {
      st2 += 'b';
    }
    for (int i = 1; i <= n; i++) {
      st3 += 'c';
    }
    string str[6];
    str[0] = st1 + st2 + st3;
    str[1] = st1 + st3 + st2;
    str[2] = st2 + st1 + st3;
    str[3] = st2 + st3 + st1;
    str[4] = st3 + st1 + st2;
    str[5] = st3 + st2 + st1;
    for (int i = 0; i <= 5; i++) {
      bool flag = true;
      for (int j = 0; j < str[i].length() - 1; j++) {
        string k;
        k += str[i][j];
        k += str[i][j + 1];
        if (k == s || k == t) {
          flag = false;
          break;
        }
      }
      if (flag) {
        cout << "YES" << endl;
        cout << str[i] << endl;
        return 0;
      }
    }
  } else {
    st1 = "abc";
    st2 = "acb";
    for (int i = 1; i <= n; i++) {
      st3 += st1;
    }
    bool flag = true;
    for (int i = 0; i < st3.length() - 1; i++) {
      string k;
      k += st3[i];
      k += st3[i + 1];
      if (k == s || k == t) {
        flag = false;
        break;
      }
    }
    if (flag) {
      cout << "YES" << endl;
      cout << st3 << endl;
      return 0;
    }
    st3 = "";
    for (int i = 1; i <= n; i++) {
      st3 += st2;
    }
    flag = true;
    for (int i = 0; i < st3.length() - 1; i++) {
      string k;
      k += st3[i];
      k += st3[i + 1];
      if (k == s || k == t) {
        flag = false;
        break;
      }
    }
    if (flag) {
      cout << "YES" << endl;
      cout << st3 << endl;
      return 0;
    }
  }
  return 0;
}
