#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:1024000000,1024000000")
using namespace std;
long long gcd(long long a, long long b) { return b ? gcd(b, a % b) : a; }
const int maxn = 1e4 + 50;
const int INFint = 0xffffff;
const long long INFll = (long long)1e18;
inline int readint() {
  int sgn = 1;
  int sum = 0;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') sgn = -sgn;
    ch = getchar();
  }
  while ('0' <= ch && ch <= '9') {
    sum = sum * 10 + (ch - '0');
    ch = getchar();
  }
  return sgn * sum;
}
inline long long readll() {
  long long sgn = 1;
  long long sum = 0;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') sgn = -sgn;
    ch = getchar();
  }
  while ('0' <= ch && ch <= '9') {
    sum = sum * 10 + (ch - '0');
    ch = getchar();
  }
  return sgn * sum;
}
int n;
string s;
int cnt;
vector<char> ans;
void input() {
  n = readint();
  cin >> s;
}
void solve() {
  int len = s.length();
  for (int i = 0; i < len; ++i) {
    char ch = s[i];
    int ind = i + 1;
    while (ind < len) {
      if (s[ind] != ch) break;
      ind++;
    }
    i = ind;
    if (ind < len) {
      ans.push_back(ch);
      ans.push_back(s[ind]);
      cnt += 2;
    }
  }
}
void output() {
  cout << n - cnt << endl;
  int Size = ans.size();
  for (int i = 0; i < Size; ++i) cout << ans[i];
  cout << endl;
}
int main() {
  input();
  solve();
  output();
  return 0;
}
