#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, n, x, y;
  cin >> a >> b >> c >> d >> n;
  if (c < d) swap(a, b), swap(c, d);
  cout << max(0, n - (c - 1) * a - (d - 1) * b) << " ";
  if (b * d >= n) {
    cout << n / d;
    return 0;
  }
  cout << b + (n - b * d) / c;
}
