#include <bits/stdc++.h>
using namespace std;
using ll = long long;
template <class T, class U>
ostream& operator<<(ostream& o, const pair<T, U>& p) {
  o << "(" << p.first << "," << p.second << ")";
  return o;
}
template <class T>
ostream& operator<<(ostream& o, const vector<T>& v) {
  o << "[";
  for (T t : v) {
    o << t << ",";
  }
  o << "]";
  return o;
}
int main() {
  int n;
  string s, t;
  cin >> n >> s >> t;
  string x = "abc";
  do {
    string tmp = x + x;
    set<string> a;
    for (int i = 0; i < (int)(5); ++i) a.insert(tmp.substr(i, 2));
    if (a.count(s) || a.count(t)) continue;
    cout << "YES\n";
    for (int i = 0; i < (int)(n); ++i) cout << x;
    cout << "\n";
    return 0;
  } while (next_permutation((x).begin(), (x).end()));
  do {
    set<string> a;
    for (int i = 0; i < (int)(2); ++i) a.insert(x.substr(i, 2));
    if (a.count(s) || a.count(t)) continue;
    cout << "YES\n";
    for (int i = 0; i < (int)(3); ++i)
      for (int j = 0; j < (int)(n); ++j) cout << x[i];
    cout << "\n";
    return 0;
  } while (next_permutation((x).begin(), (x).end()));
  cout << "NO\n";
  return 0;
}
