#include <bits/stdc++.h>
using namespace std;
inline int isB(string n) {
  int z = 0;
  int cnto = 0;
  for (int i = 0; i < n.length(); i++) {
    if (n[i] == '0') {
      z++;
    } else if (n[i] == '1') {
      cnto++;
    } else {
      return -1;
    }
  }
  if (cnto == 1) {
    return z;
  } else {
    return -1;
  }
}
int main() {
  int n;
  cin >> n;
  vector<string> V(n);
  bool zero = false;
  for (int i = 0; i < n; i++) {
    cin >> V[i];
    if (V[i][0] == '0') {
      zero = true;
    }
  }
  if (zero) {
    cout << 0 << endl;
    return 0;
  }
  string base = "";
  int cnt = 0;
  for (int i = 0; i < n; i++) {
    int z = isB(V[i]);
    if (z == -1) {
      base = V[i];
    } else {
      cnt += z;
    }
  }
  if (base.length() == 0) {
    cout << 1;
  } else {
    cout << base;
  }
  for (int i = 0; i < cnt; i++) {
    cout << 0;
  }
  cout << endl;
  return 0;
}
