#include <bits/stdc++.h>
using namespace std;
char a[100005];
char b[100005];
int main() {
  int n, num = 0;
  bool flag = 0;
  cin >> n;
  for (int i = 0; i < n; i++) {
    memset(a, 0, sizeof(a));
    cin >> a;
    if (a[0] == '0')
      flag = 1;
    else {
      int j = 1;
      while (a[j] == '0') j++;
      if (j != strlen(a) || a[0] != '1')
        strcpy(b, a);
      else
        num += j - 1;
    }
  }
  if (flag)
    cout << 0 << endl;
  else {
    if (strlen(b) > 0)
      cout << b;
    else
      cout << 1;
    for (int i = 0; i < num; i++) cout << 0;
    cout << endl;
  }
}
