#include <bits/stdc++.h>
using namespace std;
char ch[100005], ch1[100005];
int len, len1;
int judge() {
  int res = 0, sum = 0;
  for (int i = 0; i < len; ++i) {
    if (ch[i] == '1')
      ++res;
    else if (ch[i] == '0')
      ++sum;
    else
      return -1;
  }
  if (res == 1)
    return sum;
  else
    return -1;
}
int main() {
  int n, sum, res;
  bool flag;
  while (~scanf("%d", &n)) {
    sum = len1 = 0;
    flag = true;
    for (int i = 0; i < n; ++i) {
      scanf("%s", ch);
      if (!flag) continue;
      len = strlen(ch);
      if (len == 1 && ch[0] == '0') {
        flag = false;
        continue;
      }
      res = judge();
      if (res == -1) {
        len1 = len;
        ch1[len] = '\0';
        for (int i = 0; i < len1; ++i) ch1[i] = ch[i];
      } else
        sum += res;
    }
    if (!flag) {
      printf("0\n");
      continue;
    }
    if (len1 != 0) {
      printf("%s", ch1);
      for (int i = 0; i < sum; ++i) printf("0");
    } else {
      printf("1");
      for (int i = 0; i < sum; ++i) printf("0");
    }
    printf("\n");
  }
  return 0;
}
