#include <bits/stdc++.h>
#pragma GCC optimize("O3")
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wall"
#pragma GCC diagnostic ignored "-Wextra"
#pragma GCC diagnostic ignored "-Wconversion"
using namespace std;
using namespace std;
int n;
string s, ans;
int main() {
  cin >> n >> s;
  for (int i = 0; i < n; i++)
    if (ans.size() % 2 == 0 || s[i] != ans[ans.size() - 1]) ans += s[i];
  if (ans.size() % 2) ans.pop_back();
  cout << n - ans.size() << endl << ans;
}
