#include <bits/stdc++.h>
using namespace std;
int n;
string s;
int main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  cin >> n >> s;
  sort(s.begin(), s.end());
  for (int i = n - 1; i >= 0; i--)
    if (s[i - 1] != '1') cout << s[i];
  cout << endl;
  return 0;
}
