#include <bits/stdc++.h>
using namespace std;
int32_t main() {
  ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL);
  long long int n;
  cin >> n;
  string second, t;
  string x = "abc";
  cin >> second >> t;
  if (second != "aa" && second != "bb" && second != "cc" && t != "aa" &&
      t != "bb" && t != "cc") {
    if ((second[0] == t[1] && second[1] != t[0]) ||
        (second[0] != t[1] && second[1] == t[0])) {
      cout << "YES" << endl;
      string s1;
      s1 = s1 + second[1];
      s1 = s1 + second[0];
      long long int l;
      for (long long int i = 0; i < x.size(); ++i) {
        if (x[i] != second[0] && x[i] != second[1]) l = i;
      }
      s1 = s1 + x[l];
      for (long long int i = 0; i < n; ++i) {
        cout << s1;
      }
      cout << endl;
    } else if (second[0] == t[1] && second[1] == t[0]) {
      cout << "YES" << endl;
      string s1;
      string s2;
      s1 = s1 + second[0];
      long long int l;
      for (long long int i = 0; i < x.size(); ++i) {
        if (x[i] != second[0] && x[i] != second[1]) l = i;
      }
      s1 = s1 + x[l];
      s1 = s1 + second[1];
      for (long long int i = 0; i < 3; ++i) s2 = s2 + s1[2 - i];
      for (long long int i = 0; i < n; ++i) {
        if (i % 2 == 0)
          cout << s1;
        else
          cout << s2;
      }
      cout << endl;
    } else {
      if (n != 1 && second != t) {
        if (second[0] == t[0] && second[1] != t[1]) {
          cout << "YES" << endl;
          for (long long int i = 0; i < 3; ++i) {
            if (x[i] != second[0]) {
              for (long long int i1 = 0; i1 < n; ++i1) {
                cout << x[i];
              }
            }
          }
          for (long long int i = 0; i < n; ++i) {
            cout << second[0];
          }
          cout << endl;
        } else {
          cout << "YES" << endl;
          for (long long int i = 0; i < n; ++i) {
            cout << second[1];
          }
          for (long long int i = 0; i < 3; ++i) {
            if (x[i] != second[1]) {
              for (long long int i1 = 0; i1 < n; ++i1) {
                cout << x[i];
              }
            }
          }
          cout << endl;
        }
      } else {
        if (second[0] == t[0] && second[1] != t[1]) {
          cout << "YES" << endl;
          for (long long int i = 0; i < 3; ++i) {
            if (x[i] != second[0]) cout << x[i];
          }
          cout << second[0];
          cout << endl;
        } else if (second[0] != t[0] && second[1] == t[1]) {
          cout << "YES" << endl;
          cout << t[1];
          for (long long int i = 0; i < 3; ++i) {
            if (x[i] != second[1]) cout << x[i];
          }
          cout << endl;
        } else {
          cout << "YES" << endl;
          string s1;
          s1 += second[1];
          s1 += second[0];
          long long int l;
          for (long long int i = 0; i < x.size(); ++i) {
            if (x[i] != second[0] && x[i] != second[1]) l = i;
          }
          s1 = s1 + x[l];
          for (long long int i = 0; i < n; ++i) {
            cout << s1;
          }
          cout << endl;
        }
      }
    }
  } else {
    if ((second == "aa" || second == "bb" || second == "cc") &&
        (t == "aa" || t == "bb" || t == "cc")) {
      cout << "YES" << endl;
      for (long long int i = 0; i < n; ++i) {
        cout << "abc";
      }
      cout << endl;
    } else if (second == "aa" || second == "bb" || second == "cc") {
      cout << "YES" << endl;
      string s1;
      s1 += t[1];
      s1 += t[0];
      long long int l;
      for (long long int i = 0; i < x.size(); ++i) {
        if (x[i] != t[0] && x[i] != t[1]) l = i;
      }
      s1 = s1 + x[l];
      for (long long int i = 0; i < n; ++i) {
        cout << s1;
      }
      cout << endl;
    } else {
      cout << "YES" << endl;
      string s1;
      s1 += second[1];
      s1 += second[0];
      long long int l;
      for (long long int i = 0; i < x.size(); ++i) {
        if (x[i] != second[0] && x[i] != second[1]) l = i;
      }
      s1 = s1 + x[l];
      for (long long int i = 0; i < n; ++i) {
        cout << s1;
      }
      cout << endl;
    }
  }
  return 0;
}
