#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, zf = 0;
  vector<string> v;
  int bf[6] = {1, 10, 100, 1000, 10000, 100000};
  cin >> n;
  string x;
  for (int i = 0; i < n; i++) {
    cin >> x;
    if (x == "0")
      zf = 1;
    else
      v.push_back(x);
  }
  if (zf)
    cout << "0" << endl;
  else {
    string beuty = "1";
    int zn = 0;
    for (int i = 0; i < v.size(); i++) {
      string temp = v[i];
      int zeros = 0, ones = 0, others = 0;
      for (int j = 0; j < temp.size(); j++) {
        if (temp[j] == '0')
          zeros++;
        else if (temp[j] == '1')
          ones++;
        else
          others++;
      }
      if (ones == 1 && others == 0)
        zn += temp.size() - 1;
      else
        beuty = temp;
    }
    cout << beuty;
    for (int i = 0; i < zn; i++) {
      cout << "0";
    }
  }
  cout << endl;
  v.clear();
}
