#include <bits/stdc++.h>
using namespace std;
long long int a, b, k, m, n;
long long int aa[1100000];
long long int fz(long long int l, long long int r) {
  long long ll = lower_bound(aa, aa + k, l) - aa;
  long long rr = upper_bound(aa, aa + k, r) - aa;
  if (rr - ll == 0) {
    return a;
  }
  if (l == r) {
    return b * (rr - ll);
  } else {
    long long ans = 0;
    ans = b * (rr - ll) * (r - l + 1);
    return min(ans, fz(l, (l + r) / 2) + fz((((l + r) / 2) + 1), r));
  }
}
int main() {
  cin >> n >> k >> a >> b;
  for (int x = 0; x < k; x++) {
    cin >> aa[x];
  }
  sort(aa, aa + k);
  m = 1 << n;
  cout << fz(1, m) << endl;
}
