#include <bits/stdc++.h>
using namespace std;
int main() {
  char s[101];
  int n;
  cin >> n;
  cin >> s;
  if (n == 1 && s[0] == '0') {
    cout << 0;
    return 0;
  }
  cout << 1;
  for (int i = 0; i < n; i++)
    if (s[i] == '0') cout << 0;
  return 0;
}
