#include <bits/stdc++.h>
using namespace std;
int dh[4] = {0, 1, 0, -1};
int dv[4] = {-1, 0, 1, 0};
inline bool ok(string s) {
  int one = 0, zero = 0, xx = 0;
  for (int i = 0; i < s.size(); i++)
    if (s[i] == '1')
      one++;
    else if (s[i] == '0')
      zero++;
    else
      xx++;
  if (xx) return 0;
  if (one != 1) return 0;
  return 1;
}
int main() {
  ios_base::sync_with_stdio(false);
  int n, ind = 1, z = 0;
  string ans = "1", ss = "1";
  cin >> n;
  for (int i = 0; i < n; i++) {
    string x;
    cin >> x;
    if (x < "1") {
      ind = 0;
      continue;
    }
    if (ok(x))
      z += x.size() - 1;
    else
      ss = x;
  }
  if (ind == 0) {
    cout << 0;
    return 0;
  }
  cout << ss;
  for (int i = 0; i < z; i++) cout << '0';
  cout << endl;
}
