#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e6 + 10, maxm = 2e6 + 10;
const long long INF = 0x3f3f3f3f;
const long long mod = 1e9 + 7;
const double PI = acos(-1.0);
int n, m, k;
int main() {
  cin >> n >> m >> k;
  int mn = INF, mx = 0;
  for (int i = 1; i <= n; ++i) {
    int x;
    cin >> x;
    mn = min(mn, x);
  }
  for (int i = 1; i <= m; ++i) {
    int x;
    cin >> x;
    mx = max(mx, x);
  }
  if (mn < mx) {
    int ans = k + ((k / mn) * (mx - mn));
    cout << ans;
  } else
    cout << k;
  return 0;
}
