#include <bits/stdc++.h>
using namespace std;
string s[100010];
int main() {
  int n, ind = 100010, z = 0, y = 0, zz = 0;
  bool flag = false;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> s[i];
    if (s[i][0] == '0')
      flag = true;
    else {
      y = 0;
      zz = 0;
      for (int j = 0; j < s[i].size(); j++) {
        if (s[i][j] == '1') {
          y++;
          if (y == 2) {
            ind = i;
            break;
          }
        } else if (s[i][j] != '0') {
          ind = i;
          break;
        } else
          zz++;
      }
      if (ind != i) z += zz;
    }
  }
  if (flag)
    cout << "0";
  else {
    if (ind == 100010)
      cout << "1";
    else
      cout << s[ind];
    while (z) {
      cout << "0";
      z--;
    }
  }
}
