#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t;
  t = 1;
  while (t--) {
    int n;
    cin >> n;
    string s, t;
    cin >> s;
    for (int i = 0; i < n; i++) {
      if (t.size() % 2 == 0 || t.back() != s[i]) {
        t.push_back(s[i]);
      }
    }
    if (t.size() % 2 == 1) {
      t.pop_back();
    }
    cout << n - (int)(t.size()) << endl;
    cout << t;
    cout << endl;
  }
  return 0;
}
