#include <bits/stdc++.h>
using namespace std;
const int dx[] = {0, -1, 0, 1, -1, 1, 1, -1};
const int dy[] = {1, 0, -1, 0, 1, 1, -1, -1};
const long double EPS = 1e-9;
const long double PI = 3.1415926535897932384L;
const long long int INF = 9223372036854775807;
const int MOD = 1000000000 + 7;
const int MAX = 1000000 + 7;
int main() {
  int N;
  string zeros = "";
  string ans = "";
  cin >> N;
  for (int i = 0; i < N; i++) {
    string s;
    cin >> s;
    if (count(s.begin(), s.end(), '0') == s.size() - 1 and
        count(s.begin(), s.end(), '1') == 1) {
      s.erase(s.begin());
      zeros += s;
    } else if ((count(s.begin(), s.end(), '0') == s.size()))
      return cout << 0 << endl, 0;
    else
      ans = s;
  }
  string nw = ans + zeros;
  if (nw[0] == '0' or !nw.size()) cout << '1';
  return cout << nw << endl, 0;
}
