#include <bits/stdc++.h>
using namespace std;
vector<string> s;
long long i, j;
int chkbut(string s) {
  int sz = s.size();
  int zc = 0;
  int oc = 0;
  for (int i = 0; i < sz; i++) {
    if (s[i] != '0' && s[i] != '1') return -1;
    if (s[i] == '0')
      zc++;
    else
      oc++;
  }
  if (oc > 1) return -1;
  return zc;
}
int main() {
  int tc;
  int n;
  cin >> n;
  int zf = 0;
  int pos = -1;
  int sum = 0;
  for (int i = 1; i <= n; i++) {
    string t;
    cin >> t;
    s.push_back(t);
    if (t == "0") zf = 1;
    if (chkbut(t) == -1)
      pos = i - 1;
    else
      sum += chkbut(t);
  }
  if (zf) {
    cout << "0\n";
    return 0;
  }
  if (pos != -1) {
    cout << s[pos];
    for (int i = 1; i <= sum; i++) cout << "0";
    return 0;
  }
  cout << "1";
  for (int i = 1; i <= sum; i++) cout << "0";
  return 0;
}
