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