#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 5;
const double EPS = 1e-9;
const int mod = 1e9 + 7;
inline void File() {}
bool skip(string str) {
  int ret = 0;
  for (int i = 0; i < (int)(str.size()); ++i) ret += (str[i] - '0');
  return ret > 1;
}
void myMain() {
  int n;
  cin >> n;
  string Ans("1");
  int sz_zeroes = 0;
  for (int i = 0; i < n; i++) {
    string s;
    cin >> s;
    if (s == "0") {
      cout << 0;
      return;
    }
    if (skip(s))
      Ans = s;
    else
      sz_zeroes += ((int)(s.size()) - 1);
  }
  while (sz_zeroes--) Ans += '0';
  cout << Ans;
}
int32_t main() {
  ios_base::sync_with_stdio(0);
  File();
  int t = 1;
  while (t--) {
    myMain();
  }
}
