#include <bits/stdc++.h>
using namespace std;
using ll = long long;
ll n, k, a, b;
ll t[100001];
ll upper_binary(ll l, ll r, ll x) {
  if (t[k] < x) return k + 1;
  if (t[1] >= x) return 1;
  if (l >= r) return r;
  ll mid = (l + r) / 2;
  if (t[mid] >= x) {
    if (mid == 1 || t[mid - 1] < x) return mid;
    return upper_binary(l, mid - 1, x);
  }
  return upper_binary(mid + 1, r, x);
}
ll lower_binary(ll l, ll r, ll x) {
  if (t[1] > x) return 0;
  if (t[k] <= x) return k;
  if (l >= r) return r;
  ll mid = (l + r) / 2;
  if (t[mid] <= x) {
    if (mid == k || t[mid + 1] > x) return mid;
    return lower_binary(mid + 1, r, x);
  }
  return lower_binary(l, mid - 1, x);
}
ll rec(ll l, ll r) {
  ll start = upper_binary(1, k, l);
  ll finish = lower_binary(1, k, r);
  ll res = ((start > finish) ? a : b * (r - l + 1) * (finish - start + 1));
  if (l != r && finish >= start) {
    ll mid = (l + r) / 2;
    res = min(res, rec(l, mid) + rec(mid + 1, r));
  }
  return res;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin >> n >> k >> a >> b;
  for (int i = 1; i <= k; i++) cin >> t[i];
  sort(t + 1, t + k + 1);
  cout << rec(1, 1 << n) << flush;
  return 0;
}
