#include <bits/stdc++.h>
using namespace std;
template <class T>
int getbit(T s, int i) {
  return (s >> i) & 1;
}
template <class T>
T onbit(T s, int i) {
  return s | (T(1) << i);
}
template <class T>
T offbit(T s, int i) {
  return s & (~(T(1) << i));
}
template <class T>
int cntbit(T s) {
  return __builtin_popcount(s);
}
template <class T>
T gcd(T a, T b) {
  T r;
  while (b != 0) {
    r = a % b;
    a = b;
    b = r;
  }
  return a;
}
template <class T>
T lcm(T a, T b) {
  return a / gcd(a, b) * b;
}
long long n, h, x[400005];
double p;
double f[2005][2005][2][2];
double cal(int l, int r, int u, int v) {
  if (f[l][r][u][v] >= 0) return f[l][r][u][v];
  if (l == r) {
    if (u == 1 && x[l] - x[l - 1] < h) {
      double res;
      if (v)
        res = min(h, x[r + 1] - x[r] - h);
      else
        res = min(h, x[r + 1] - x[r]);
      return f[l][r][u][v] = res;
    }
    if (v == 1 && x[r + 1] - x[r] < h) {
      double res;
      if (u)
        res = min(h, x[l] - x[l - 1] - h);
      else
        res = min(h, x[l] - x[l - 1]);
      return f[l][r][u][v] = res;
    }
    double r1 = min(h, x[r + 1] - x[r]);
    if (v) r1 = min(h, x[r + 1] - x[r] - h);
    double l1 = min(h, x[l] - x[l - 1]);
    if (u) l1 = min(h, x[l] - x[l - 1] - h);
    double res = r1 * p + (1 - p) * l1;
    return f[l][r][u][v] = res;
  }
  double &res = f[l][r][u][v];
  if (u == 1 && x[l] - x[l - 1] < h) {
    double l1 = min(h, x[l + 1] - x[l]);
    res = l1 + cal(l + 1, r, 1, v);
  } else if (v == 1 && x[r + 1] - x[r] < h) {
    double r1 = min(h, x[r] - x[r - 1]);
    res = r1 + cal(l, r - 1, u, 1);
  } else {
    res = 0;
    double l1 = min(h, x[l + 1] - x[l]);
    res += 0.5 * p * (l1 + cal(l + 1, r, 1, v));
    double r1 = min(h, x[r] - x[r - 1]);
    res += 0.5 * (1 - p) * (r1 + cal(l, r - 1, u, 1));
    l1 = min(h, x[l] - x[l - 1]);
    if (u) l1 = min(h, x[l] - x[l - 1] - h);
    res += 0.5 * (1 - p) * (l1 + cal(l + 1, r, 0, v));
    r1 = min(h, x[r + 1] - x[r]);
    if (v) r1 = min(h, x[r + 1] - x[r] - h);
    res += 0.5 * (p) * (r1 + cal(l, r - 1, u, 0));
  }
  return res;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cin >> n >> h >> p;
  p = 1 - p;
  for (int i = (1); i <= (n); ++i) cin >> x[i];
  sort(x + 1, x + n + 1);
  x[0] = -1000000005;
  x[n + 1] = 1000000005;
  for (int i = 0; i < (2005); ++i)
    for (int j = 0; j < (2005); ++j)
      for (int u = 0; u < (2); ++u)
        for (int v = 0; v < (2); ++v) f[i][j][u][v] = -1;
  double res = cal(1, n, 0, 0);
  cout << fixed << setprecision(9) << res << endl;
  return 0;
}
