#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
int a[200020];
map<int, int> mp;
long long gcd(long long a, long long b) { return b == 0 ? a : gcd(b, a % b); }
long long lcm(long long a, long long b) { return a / gcd(a, b) * b; }
int rd() {
  int flag = 1;
  char c = getchar();
  while (c < '0' && c > '9') {
    if (c == '-') flag = -1;
    c = getchar();
  }
  int sum = 0;
  while (c >= '0' && c <= '9') {
    sum = (sum << 1) + (sum << 3) + (c - '0');
    c = getchar();
  }
  return sum * flag;
}
long long RD() {
  int flag = 1;
  char c = getchar();
  while (c < '0' && c > '9') {
    if (c == '-') flag = -1;
    c = getchar();
  }
  long long sum = 0;
  while (c >= '0' && c <= '9') {
    sum = (sum << 1) + (sum << 3) + (c - '0');
    c = getchar();
  }
  return sum * flag;
}
int main() {
  int n;
  cin >> n;
  string s;
  cin >> s;
  int sum = 0;
  for (int i = 0; i < s.size();) {
    if (i % 2 == 0) {
      char c = s[i];
      i++;
      while (i < s.size() && s[i] == c) {
        sum++;
        s.erase(i, 1);
      }
    } else
      i++;
  }
  if (s.size() % 2 == 1) sum++, s.erase(s.size() - 1, 1);
  cout << sum << endl << s << endl;
  return 0;
}
