#include <bits/stdc++.h>
using namespace std;
void c_p_c() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
}
bool is_not_beautiful(string num) {
  int ones = 0;
  bool diff = false;
  for (char c : num) {
    if (c == '1') {
      ones++;
    }
    if (c != '1' && c != '0') {
      diff = true;
    }
  }
  return ones > 1 || diff;
}
bool is_zero(string num) {
  if (num[0] == '0') {
    return true;
  }
  return false;
}
int main() {
  c_p_c();
  int n;
  int zeros = 0;
  string num;
  string res = "";
  cin >> n;
  for (int i = 0; i < (n); i++) {
    cin >> num;
    if (is_zero(num)) {
      cout << "0" << endl;
      return 0;
    }
    if (is_not_beautiful(num)) {
      res += num;
    } else {
      zeros += num.size() - 1;
    }
  }
  if (res.size()) {
    cout << res;
  } else {
    cout << "1";
  }
  for (int i = 0; i < (zeros); i++) {
    cout << '0';
  }
  cout << endl;
  return 0;
}
