#include <bits/stdc++.h>
using namespace std;
int main(int argc, char const *argv[]) {
  long long int n, e, t;
  std::cin >> n >> e >> t;
  if (n > 2000) throw runtime_error("error");
  vector<long long int> x(n);
  for (long long int i = 0; i < n; i++) scanf("%lld", &x[i]);
  vector<long long int> dp(n + 1, 1000000000000000000);
  dp[0] = e;
  for (int now = 0; now < n; now++) {
    for (int d = 0; d + now < n; d++) {
      long long int ad = max(t, 2 * (x[now + d] - x[now]));
      long long int nxt = now + d + 1;
      dp[nxt] = min(dp[nxt], dp[now] + ad);
    }
  }
  std::cout << dp[n] << '\n';
  return 0;
}
