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