#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int n, i, j;
  std::cin >> n;
  string s;
  cin >> s;
  string res = "";
  j = 1;
  i = 0;
  while (j < n) {
    if (s[i] == s[j]) {
      j++;
    } else {
      res += s[i];
      res += s[j];
      i = j + 1;
      j += 2;
    }
  }
  std::cout << n - res.length() << std::endl;
  cout << res << "\n";
}
