#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 7;
const int MAXN = 2e5 + 5;
long long N, x, f, res;
int a[MAXN];
int main(void) {
  scanf("%lld", &N);
  for (int i = 1; i <= N; i++) {
    scanf("%d", &a[i]);
  }
  scanf("%lld %lld", &x, &f);
  for (int i = 1; i <= N; i++) {
    if (a[i] <= x) continue;
    int p = a[i] / (x + f);
    int k = a[i] % (x + f);
    if (k > x) p += 1;
    if (p)
      res += p;
    else
      res += 1;
  }
  printf("%lld\n", res * f);
  return 0;
}
