#include <bits/stdc++.h>   using namespace std;   int main() {     int c, d, n, m, k;     cin >> c >> d >> n >> m >> k;     int users = n * m - k;     int ans = 1000000000;     for (int i = 0; i <= m; i++)       for (int j = 0; j <= 10000; j++) {         if (i * n + j >= users) {           if (c * i + j * d < ans) ans = c * i + j * d;         }       }     cout << ans;   }   