#include <bits/stdc++.h>
using namespace std;
using namespace std::chrono;
long long power(long long x, unsigned long long y) {
  long long res = 1;
  while (y > 0) {
    if (y & 1) {
      res = res * x;
    }
    y = y >> 1;
    x = x * x;
  }
  return res;
}
long long powermod(long long x, unsigned long long y, long long p) {
  long long res = 1;
  x = x % p;
  while (y > 0) {
    if (y & 1) {
      res = (res * x) % p;
    }
    y = y >> 1;
    x = (x * x) % p;
  }
  return res;
}
long long min(long long a, long long b) { return a < b ? a : b; }
long long max(long long a, long long b) { return a > b ? a : b; }
void snow() {
  long long n;
  cin >> n;
  string s, t;
  cin >> s >> t;
  string abc = "abc";
  vector<string> res;
  do {
    string curr = "";
    for (long long i = 0; i < n; i++) curr += abc;
    res.push_back(curr);
    curr.clear();
    for (long long i = 0; i < n; i++) {
      curr.push_back(abc[0]);
    }
    for (long long i = 0; i < n; i++) {
      curr.push_back(abc[1]);
    }
    for (long long i = 0; i < n; i++) {
      curr.push_back(abc[2]);
    }
    res.push_back(curr);
  } while (next_permutation(abc.begin(), abc.end()));
  for (auto x : res) {
    bool ok = true;
    for (long long i = 0; i < 3 * n - 1; i++) {
      if (s[0] == x[i] && s[1] == x[i + 1]) {
        ok = false;
      }
      if (t[0] == x[i] && t[1] == x[i + 1]) {
        ok = false;
      }
    }
    if (ok) {
      cout << "YES\n";
      cout << x << '\n';
      exit(0);
    }
  }
  cout << "NO\n";
}
int32_t main() {
  auto start = high_resolution_clock::now();
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  long long _;
  _ = 1;
  while (_--) snow();
  auto stop = high_resolution_clock::now();
  auto duration = duration_cast<microseconds>(stop - start);
  return 0;
}
