#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d, e;
  cin >> a >> b >> c >> d >> e;
  int rem = 0, remm = 0;
  int aa = a, bb = b, cc = c, dd = d, ee = e;
  if (c > d) {
    int fi = b * (d - 1) + a * (c - 1);
    while (fi < e) {
      if (a == 0) break;
      rem++;
      fi -= (c - 1);
      e -= c;
      a--;
    }
    while (fi < e) {
      if (b == 0) break;
      rem++;
      fi -= (d - 1);
      e -= d;
      b--;
    }
  } else {
    int fi = b * (d - 1) + a * (c - 1);
    while (fi < e) {
      if (b == 0) break;
      rem++;
      fi -= (d - 1);
      e -= d;
      b--;
    }
    while (fi < e) {
      if (a == 0) break;
      rem++;
      fi -= (c - 1);
      e -= c;
      a--;
    }
  }
  a = aa, b = bb, c = cc, d = dd, e = ee;
  if (c < d) {
    while (c <= e) {
      if (a == 0) break;
      remm++;
      e -= c;
      a--;
    }
    while (d <= e) {
      if (b == 0) break;
      remm++;
      e -= d;
      b--;
    }
  } else {
    while (d <= e) {
      if (b == 0) break;
      remm++;
      e -= d;
      b--;
    }
    while (c <= e) {
      if (a == 0) break;
      remm++;
      e -= c;
      a--;
    }
  }
  cout << rem << " " << remm << endl;
  return 0;
}
