#include <bits/stdc++.h>
using namespace std;
const long long LIM = 1e18;
vector<long long> a, b, c, d;
void dfs1(long long val, int st) {
  c.push_back(val);
  for (int i = st; i < (int)a.size(); i++) {
    if (LIM / a[i] >= val) dfs1(val * a[i], i);
  }
}
void dfs2(long long val, int st) {
  d.push_back(val);
  for (int i = st; i < (int)b.size(); i++) {
    if (LIM / b[i] >= val) dfs2(val * b[i], i);
  }
}
long long cal(long long num) {
  int j = 0;
  long long sum = 0;
  for (int i = c.size() - 1; i >= 0; i--) {
    while (j < (int)d.size() && d[j] <= num / c[i]) j++;
    sum += j;
  }
  return sum;
}
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    long long t;
    cin >> t;
    if (i & 1)
      a.push_back(t);
    else
      b.push_back(t);
  }
  long long k;
  cin >> k;
  dfs1(1ll, 0);
  dfs2(1ll, 0);
  sort(c.begin(), c.end());
  sort(d.begin(), d.end());
  long long l = 0, r = 1e18 + 1;
  while (l < r) {
    long long m = (l + r) / 2;
    if (cal(m) >= k)
      r = m;
    else
      l = m + 1;
  }
  cout << l << endl;
  return 0;
}
