#include <bits/stdc++.h>
using namespace std;
string ans;
char buf[100005];
int z;
bool has_zero;
bool is_beautiful() {
  if (buf[0] != '1') return false;
  int len = strlen(buf);
  for (int i = 1; i < len; i++)
    if (buf[i] != '0') return false;
  return true;
}
int main() {
  ans = "1";
  int n;
  scanf(" %d", &n);
  for (int i = 0; i < n; i++) {
    scanf(" %s", buf);
    if (strlen(buf) == 1 && buf[0] == '0') {
      has_zero = true;
    } else if (is_beautiful()) {
      z += strlen(buf) - 1;
    } else {
      ans = (string)buf;
    }
  }
  if (has_zero) {
    printf("0\n");
    return 0;
  }
  printf("%s", ans.c_str());
  for (int i = 0; i < z; i++) printf("0");
  printf("\n");
  return 0;
}
