#include <bits/stdc++.h>
using namespace std;
template <class T>
T gcd(T a, T b) {
  if (b == 0)
    return a;
  else
    return gcd(b, a % b);
}
template <class T>
T power(T a, T b) {
  T result = 1;
  while (b > 0) {
    if (b & 1) result = result * a;
    a = a * a;
    b >>= 1;
  }
  return result;
}
template <class T>
T powerMod(T a, T b, T c) {
  T result = 1 % c;
  while (b > 0) {
    if (b & 1) result = (result * a) % c;
    a = (a * a) % c;
    b >>= 1;
  }
  return result;
}
void eval() {
  string str, first = "1";
  int n, count0, j, i, temp, len, counter;
  cin >> n;
  count0 = 0;
  for (j = 0; j < n; j++) {
    temp = 0;
    cin >> str;
    len = str.length();
    if (str[0] == '0') {
      cout << "0\n";
      return;
    }
    counter = 0;
    for (i = 0; i < len; i++) {
      if (str[i] == '1') counter++;
      if (str[i] == '0') {
        temp++;
      }
      if (str[i] > '1' || counter > 1) {
        first = str;
        temp = 0;
        break;
      }
    }
    count0 += temp;
  }
  cout << first;
  for (i = 0; i < count0; i++) cout << "0";
}
int main() {
  cin.sync_with_stdio(0);
  cout.sync_with_stdio(0);
  eval();
  return 0;
}
