#include <bits/stdc++.h>
using namespace std;
const double pi = acos(-1);
int main() {
  int n;
  string s;
  cin >> n >> s;
  for (int i = 1; i < n; ++i)
    if (s[i] != s[i - 1]) {
      cout << "YES" << '\n' << s[i - 1] << s[i];
      return 0;
    }
  cout << "NO";
}
