#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, count = 0;
  string s;
  cin >> n >> s;
  vector<int> index;
  for (int i = 0; i < n - 1; ++i) {
    if (s[i] == s[i + 1] && (i + 1 + count) % 2) {
      ++count;
      index.push_back(i);
    }
  }
  if ((s.size() - count) % 2) {
    ++count;
    index.push_back(n - 1);
  }
  cout << count << endl;
  int j = 0;
  for (int i = 0; i < n; ++i) {
    if (j < index.size() && i == index[j]) {
      ++j;
      continue;
    } else
      cout << s[i];
  }
}
