#include <bits/stdc++.h>
using namespace std;
void k_007() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
}
bool sortbysec(const pair<long long, long long> &a,
               const pair<long long, long long> &b) {
  return (a.second < b.second);
}
long long gcd(long long a, long long b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
long long prime(long long n) {
  if (n == 1 || n == 0) return 0;
  long long flag = 1;
  for (long long i = 2; i <= sqrt(n); i++) {
    if (n % i == 0) {
      flag = 0;
      break;
    }
  }
  return flag;
}
long long power(long long x, long long y) {
  if (y == 0)
    return 1;
  else if (y % 2 == 0)
    return ((power(x, y / 2) % 1000000007) * (power(x, y / 2) % 1000000007)) %
           1000000007;
  else
    return ((x % 1000000007) * (power(x, y / 2) % 1000000007) *
            (power(x, y / 2) % 1000000007)) %
           1000000007;
}
long long lcm(long long a, long long b) { return (a * b) / gcd(a, b); }
string a[] = {"abc", "acb", "bac", "bca", "cab", "cba"};
int32_t main() {
  k_007();
  long long n;
  cin >> n;
  string s, t;
  cin >> s >> t;
  bool ok = false;
  if (s[0] == s[1] || t[0] == t[1]) ok = true;
  for (long long i = 0; i < 6; i++) {
    string tmp = "";
    tmp += a[i][2];
    tmp += a[i][0];
    if (!ok && a[i].substr(0, 2) != s && a[i].substr(0, 2) != t &&
        a[i].substr(1, 2) != s && a[i].substr(1, 2) != t) {
      cout << "YES" << endl;
      for (long long k = 0; k < 3; k++)
        for (long long j = 0; j < n; j++) cout << a[i][k];
      cout << endl;
      return 0;
    }
    if (ok && a[i].substr(0, 2) != s && a[i].substr(0, 2) != t &&
        a[i].substr(1, 2) != s && a[i].substr(1, 2) != t &&
        ((n == 1) || (n > 1 && tmp != s && tmp != t))) {
      cout << "YES" << endl;
      for (long long j = 0; j < n; j++) cout << a[i];
      cout << endl;
      return 0;
    }
  }
  cout << "NO" << endl;
}
