#include <bits/stdc++.h>
using namespace std;
const int mm = 2e5 + 100;
long long int d[mm];
int main() {
  long long int n, m, i, j, t, a, b, c, p, k, kk, x, f;
  cin >> n;
  for (i = 0; i < n; i++) {
    scanf("%lld", &d[i]);
  }
  scanf("%lld%lld", &x, &f);
  k = 0;
  for (i = 0; i < n; i++) {
    if (d[i] > x) {
      d[i] -= x;
      k += d[i] / (f + x) * f;
      if (d[i] % (k + x)) k += f;
    }
  }
  cout << k << endl;
}
