#include <bits/stdc++.h>
using namespace std;
vector<char> a;
string s;
long long n;
int main() {
  cin >> n;
  cin >> s;
  a.push_back(s[0]);
  for (int i = 1; i < n; i++) {
    if (a.size() % 2) {
      if (s[i] != a[a.size() - 1]) a.push_back(s[i]);
    } else {
      a.push_back(s[i]);
    }
  }
  if (a.size() % 2) a.pop_back();
  cout << n - a.size() << endl;
  for (int i = 0; i < a.size(); i++) cout << a[i];
}
