#include <bits/stdc++.h>
using namespace std;
template <class c>
struct rge {
  c b, e;
};
template <class c>
rge<c> range(c i, c j) {
  return {i, j};
}
struct printer {
  ~printer() { cerr << endl; }
  template <class c>
  printer& operator,(c x) {
    cerr << boolalpha << x;
    return *this;
  }
  printer& operator,(string x) {
    cerr << x;
    return *this;
  }
  template <class c, class d>
  printer& operator,(pair<c, d> x) {
    return *this, "(", x.first, ", ", x.second, ")";
  }
  template <class... d, template <class...> class c>
  printer& operator,(c<d...> x) {
    return *this, range(begin(x), end(x));
  }
  template <class c>
  printer& operator,(rge<c> x) {
    *this, "[";
    for (auto it = x.b; it != x.e; ++it) *this, (it == x.b ? "" : ", "), *it;
    return *this, "]";
  }
};
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
long long my_rand(long long l, long long r) {
  return uniform_int_distribution<long long>(l, r)(rng);
}
const long long mod = 1e9 + 7;
const long long inf = -1;
void print1(string s, long long n) {
  for (long long i = 1; i <= n; i++) cout << s;
}
signed main() {
  string s, t;
  long long n;
  cin >> n >> s >> t;
  cout << "YES" << endl;
  if ((s == "ab" or s == "ba") and (t == "ab" or t == "ba")) {
    print1("a", n);
    print1("c", n);
    print1("b", n);
  } else if ((s == "bc" or s == "cb") and (t == "bc" or t == "cb")) {
    print1("b", n);
    print1("a", n);
    print1("c", n);
  } else if ((s == "ac" or s == "ca") and (t == "ac" or t == "ca")) {
    print1("c", n);
    print1("b", n);
    print1("a", n);
  } else if ((s == "ab" or s == "cb") and ((t == "ab" or t == "cb"))) {
    print1("b", n);
    print1("a", n);
    print1("c", n);
  } else if ((s == "ba" or s == "bc") and ((t == "ba" or t == "bc"))) {
    print1("a", n);
    print1("c", n);
    print1("b", n);
  } else if ((s == "ac" or s == "ab") and ((t == "ac" or t == "ab"))) {
    print1("b", n);
    print1("c", n);
    print1("a", n);
  } else if ((s == "ac" or s == "bc") and ((t == "ac" or t == "bc"))) {
    print1("c", n);
    print1("a", n);
    print1("b", n);
  } else if ((s == "ba" or s == "ca") and (t == "ba" or t == "ca")) {
    print1("a", n);
    print1("c", n);
    print1("b", n);
  } else if ((s == "ca" or s == "cb") and (t == "ca" or t == "cb")) {
    print1("a", n);
    print1("b", n);
    print1("c", n);
  } else if ((s == "ba" or s == "cb" or s == "ac") or
             ((t == "ba" or t == "cb" or t == "ac"))) {
    print1("abc", n);
  } else
    print1("cba", n);
  cout << endl;
}
