#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, r, x;
  cin >> n >> m >> r;
  int b_min = INT_MAX, s_max = INT_MIN;
  for (int i = 0; i < n; ++i) {
    cin >> x;
    b_min = min(b_min, x);
  }
  for (int i = 0; i < m; ++i) {
    cin >> x;
    s_max = max(s_max, x);
  }
  int res = r / b_min * s_max + r % b_min;
  if (r > res) {
    cout << r << endl;
  } else {
    cout << res << endl;
  }
  return 0;
}
