#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, x, f, q = 0;
  cin >> n;
  vector<long long> a(n);
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  cin >> x >> f;
  for (int i = 0; i < n; i++) {
    q += (a[i] > x) * (((a[i] - x) / (x + f)) + ((a[i] - x) % (x + f) > 0));
  }
  cout << q * f;
  return 0;
}
