#include <bits/stdc++.h>
using namespace std;
void setIn(string s) { freopen(s.c_str(), "r", stdin); }
void setOut(string s) { freopen(s.c_str(), "w", stdout); }
int main() {
  int c, d, n, m, k;
  cin >> c >> d >> n >> m >> k;
  int num = n * m - k;
  if (n * m - k <= 0) {
    cout << 0 << endl;
  } else {
    int MIN_PROBS = 1000000;
    int afinal = 0;
    int bfinal = 0;
    int b = num;
    while (b >= 0) {
      int a = ceil((double)(num - b) / n);
      if (a * c + b * d <= MIN_PROBS) {
        MIN_PROBS = a * c + b * d;
        afinal = a;
        bfinal = b;
      }
      b--;
    }
    cout << MIN_PROBS << endl;
  }
}
