#include <bits/stdc++.h>
using namespace std;
int a[35], b[35];
int main() {
  int n, m, r;
  scanf("%d%d%d", &n, &m, &r);
  int maxx = 0, minn = 0x3f3f3f3f;
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    minn = min(a[i], minn);
  }
  for (int i = 1; i <= m; i++) {
    scanf("%d", &b[i]);
    maxx = max(b[i], maxx);
  }
  if (minn >= maxx) {
    printf("%d\n", r);
  } else {
    int temp = r % minn;
    int temp1 = r / minn;
    temp1 *= maxx;
    r = temp + temp1;
    printf("%d\n", r);
  }
}
