#include<iostream>
#include<cmath>
using namespace std;
typedef long long int LL;
LL base[25];

LL check(LL a,int n,int k){
	if(n==0){
		if(a==0)return 10;
		else return 0;
	}
	if(n<0){
		if(a==0)return 1;
		else return 0;
	}
	LL b,c,d;
	LL t;
	t=base[n];
	for(int i=0;i<k;i++)t*=10;
	b=(a+t*15)/t-15;
	c=0;
	if(-9<=b && b<=9){
		d=10-abs(b);
		if(k==0 && b>=0)d--;
		c=check(a-b*t,n-2,k+1)*d;
	}
	if(-9<=b+1 && b+1<=9){
		d=10-abs(b+1);
		if(k==0 && b+1>=0)d--;
		c+=check(a-(b+1)*t,n-2,k+1)*d;
	}
	return c;
}

int main(){
	LL a,b,c;
	LL s=0;
	int i,j,k;
	for(i=1,a=1;i<=20;i++){
		a*=10;
		base[i]=a-1;
	}
	cin>>a;
	for(i=20;i>0;i--){
		s+=check(a,i,0);
	}
	cout<<s<<endl;
}

#include <bits/stdc++.h>

using namespace std;
typedef long long ll;

#define REP(i, n) for (ll i = 0; i < (ll)(n); i++)
#define REPD(i, n) for (ll i = (ll)(n)-1; i >= 0; i--)
#define FOR(i, a, b) for (ll i = (a); i <= (b); i++)
#define FORD(i, a, b) for (ll i = (a); i >= (b); i--)
#define ALL(x) (x).begin(), (x).end()
#define SIZE(x) ((ll)(x).size())
#define MAX(x) *max_element(ALL(x))
#define MIN(x) *min_element(ALL(x))
#define INF 1000000000000
#define MOD 1000000007
#define PB push_back
#define MP make_pair
#define F first
#define S second

void solve() {
  ll N, A, B, dist = 0;
  cin >> N >> A >> B;
  vector<ll> X(N);
  REP(i, N) { cin >> X[i]; }
  sort(ALL(X));
  FOR(i, 0, N - 1 - 1) {
    if ((X[i + 1] - X[i]) * A < B) {
      dist += (X[i + 1] - X[i]) * A;
    } else {
      dist += B;
    }
  }
  cout << dist << endl;
}

signed main() {
  solve();

  return 0;
}