#include <bits/stdc++.h>
using namespace std;
int C, D, N, M, K;
int main() {
  cin >> C >> D >> N >> M >> K;
  int kk = N * M - K;
  if (kk < 0) return puts("0"), 0;
  cout << max(0,
              min(kk * D, min((kk + N - 1) / N * C, kk / N * C + kk % N * D)))
       << endl;
}
