#include <bits/stdc++.h>
using namespace std;
int n;
string s, t;
char res[5] = "abc";
int main() {
  scanf("%d", &n);
  cin >> s >> t;
  puts("YES");
  if (s[0] != s[1] && t[0] != t[1]) {
    while (1) {
      if (!((res[0] == s[0] && res[1] == s[1]) ||
            (res[0] == t[0] && res[1] == t[1]) ||
            (res[1] == s[0] && res[2] == s[1]) ||
            (res[1] == t[0] && res[2] == t[1])))
        break;
      next_permutation(res, res + 3);
    }
    for (int i = 0; i < 3; i++)
      for (int j = 0; j < n; j++) cout << res[i];
  } else {
    if (t != "aa" && t != "bb" && t != "cc") swap(s, t);
    if (s != "ab" && s != "bc" && s != "ca")
      for (int i = 1; i <= n; i++) cout << "abc";
    else if (s != "ac" && s != "cb" && s != "ba")
      for (int i = 1; i <= n; i++) cout << "acb";
    else if (s != "ba" && s != "ac" && s != "cb")
      for (int i = 1; i <= n; i++) cout << "bac";
    else if (s != "bc" && s != "ca" && s != "ab")
      for (int i = 1; i <= n; i++) cout << "bca";
    else if (s != "ca" && s != "ab" && s != "bc")
      for (int i = 1; i <= n; i++) cout << "cab";
    else
      for (int i = 1; i <= n; i++) cout << "cba";
  }
  return 0;
}
