#include <bits/stdc++.h>
using namespace std;
using namespace std;
int main() {
  int n, i;
  scanf("%d", &n);
  string abc = "abc", c, d, e, f, res;
  res = abc;
  cin >> c >> d;
  while (1) {
    for (i = 0; i < n; i++) e += abc;
    f = string(n, abc[0]) + string(n, abc[1]) + string(n, abc[2]);
    if (e.find(c) == string::npos && e.find(d) == string::npos) {
      puts("YES");
      cout << e;
      printf("\n");
      return 0;
    } else if (f.find(c) == string::npos && f.find(d) == string::npos) {
      puts("YES");
      cout << f;
      printf("\n");
      return 0;
    } else
      next_permutation(abc.begin(), abc.end());
    if (res == abc) break;
    e.clear();
    f.clear();
  }
  puts("NO");
  return 0;
}
