#include <bits/stdc++.h>
#pragma GCC optimize(2)
using namespace std;
long long GCD(long long a, long long b) { return b == 0 ? a : GCD(b, a % b); }
const long long inf = 1e18;
const long long mod = 1e9 + 7;
double pi = acos(-1.0);
string str, s;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  cin >> str >> s;
  cout << "YES" << endl;
  if (str[0] == s[0] && str[1] == s[1]) {
    if (str[1] != s[0]) {
      for (int i = 1; i <= n; i++) cout << str[1];
      for (int i = 1; i <= n; i++) cout << str[0];
      char ch;
      for (char i = 'a'; i <= 'c'; i++) {
        bool flag = false;
        for (int j = 0; j < 2; j++)
          if (str[j] == i) flag = true;
        if (!flag) {
          ch = i;
          break;
        }
      }
      for (int i = 1; i <= n; i++) cout << ch;
    } else {
      for (int i = 1; i <= n; i++) cout << "abc";
    }
  } else if (str[0] == s[1] && str[1] == s[0]) {
    string p, q;
    p += str[0];
    for (char i = 'a'; i <= 'c'; i++) {
      bool flag = false;
      for (int j = 0; j < 2; j++)
        if (str[j] == i) flag = true;
      if (!flag) {
        p += i;
        break;
      }
    }
    p += str[1];
    q = p;
    reverse(p.begin(), p.end());
    for (int i = 1; i <= n; i++)
      if (i % 2)
        cout << p;
      else
        cout << q;
  } else if (str[0] == s[0]) {
    if (str[1] != str[0] && s[1] != s[0]) {
      for (int i = 1; i <= n; i++) cout << str[1];
      for (int i = 1; i <= n; i++) cout << s[1];
      for (int i = 1; i <= n; i++) cout << str[0];
    } else {
      char ch;
      for (char i = 'a'; i <= 'c'; i++) {
        bool flag = false;
        for (int j = 0; j < 2; j++)
          if (str[j] == i) flag = true;
        for (int j = 0; j < 2; j++)
          if (s[j] == i) flag = true;
        if (!flag) {
          ch = i;
          break;
        }
      }
      string p;
      if (str[0] == str[1])
        p += s[0], p += ch, p += s[1];
      else
        p += str[0], p += ch, p += str[1];
      for (int i = 1; i <= n; i++) cout << p;
    }
  } else if (str[1] == s[1]) {
    if (str[1] != str[0] && s[1] != s[0]) {
      for (int i = 1; i <= n; i++) cout << str[1];
      for (int i = 1; i <= n; i++) cout << str[0];
      for (int i = 1; i <= n; i++) cout << s[0];
    } else {
      char ch;
      for (char i = 'a'; i <= 'c'; i++) {
        bool flag = false;
        for (int j = 0; j < 2; j++)
          if (str[j] == i) flag = true;
        for (int j = 0; j < 2; j++)
          if (s[j] == i) flag = true;
        if (!flag) {
          ch = i;
          break;
        }
      }
      string p;
      if (str[0] == str[1])
        p += s[0], p += ch, p += s[1];
      else
        p += str[0], p += ch, p += str[1];
      for (int i = 1; i <= n; i++) cout << p;
    }
  } else if (str[0] == s[1] || str[1] == s[0]) {
    for (int i = 1; i <= n; i++) cout << str[1];
    for (int i = 1; i <= n; i++) cout << str[0];
    if (str[0] == s[1]) {
      for (int i = 1; i <= n; i++) cout << s[0];
    } else {
      for (int i = 1; i <= n; i++) cout << s[1];
    }
  } else if (str[1] == str[0] || s[0] == s[1]) {
    if (str[1] == str[0] && s[0] == s[1]) {
      char ch;
      for (char i = 'a'; i <= 'c'; i++) {
        bool flag = false;
        for (int j = 0; j < 2; j++)
          if (str[j] == i) flag = true;
        for (int j = 0; j < 2; j++)
          if (s[j] == i) flag = true;
        if (!flag) {
          ch = i;
          break;
        }
      }
      for (int i = 1; i <= n; i++) cout << str[0] << ch << s[0];
    } else if (str[1] == str[0]) {
      for (int i = 1; i <= n; i++) cout << s[0] << str[0] << s[1];
    } else {
      for (int i = 1; i <= n; i++) cout << str[0] << s[0] << str[1];
    }
  }
}
