#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int n, m, r, min = 1001, max = 0;
  int s[101], b[101];
  cin >> n >> m >> r;
  for (int i = 0; i < n; i++) {
    cin >> s[i];
    if (s[i] < min) {
      min = s[i];
    }
  }
  for (int i = 0; i < m; i++) {
    cin >> b[i];
    if (b[i] > max) {
      max = b[i];
    }
  }
  if (max <= min) {
    cout << r;
  } else {
    cout << r % min + (r / min) * max;
  }
  return 0;
}
