#include <bits/stdc++.h>
using namespace std;
const int N = 100000 + 10;
int get_0(int x) {
  int cnt = 0;
  while (x /= 10) {
    cnt++;
  }
  return cnt;
}
int main() {
  int n;
  while (~scanf("%d", &n)) {
    char tmp[N];
    int flag_0 = 0;
    int cnt = 0;
    for (int i = 0; i < n; i++) {
      char x[N];
      scanf("%s", x);
      if (x[0] == '0') {
        flag_0 = 1;
      } else {
        int len = strlen(x);
        int flag = 0;
        int cnt1 = 0;
        for (int i = 0; i < len; i++) {
          if (x[i] == '1' && i == 0) {
            continue;
          } else if (x[i] != '0') {
            flag = 1;
            break;
          } else {
            cnt1++;
          }
        }
        if (flag) {
          for (int i = 0; i < len; i++) {
            tmp[i] = x[i];
          }
          tmp[len] = '\0';
        } else {
          cnt += cnt1;
        }
      }
    }
    if (flag_0) {
      printf("0\n");
    } else {
      if (tmp[0]) {
        printf("%s", tmp);
      } else {
        printf("1");
      }
      for (int i = 1; i <= cnt; i++) {
        printf("0");
      }
      printf("\n");
    }
  }
  return 0;
}
