#include <bits/stdc++.h>
using namespace std;
long long pre[2001][2001];
long long dp[2001][2001];
long long find_ans(long long l, long long n, vector<long long>& v) {
  if (dp[l][n] != -1) return dp[l][n];
  long long ans = pre[l][n];
  for (long long j = l; j < n; j++) {
    ans = min(ans, pre[l][j] + find_ans(j + 1, n, v));
  }
  return dp[l][n] = ans;
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long n, e, t;
  cin >> n >> e >> t;
  vector<long long> v(n + 1, 0);
  for (long long i = 0; i < n; i++) {
    cin >> v[i + 1];
  }
  for (long long i = 1; i <= n; i++) {
    for (long long j = i; j <= n; j++) {
      pre[i][j] = 2 * (v[j] - v[i]) +
                  (j - i + 1) * max(t - 2 * (v[j] - v[i]), (long long)0);
      dp[i][j] = -1;
    }
  }
  long long ans = e;
  ans += find_ans(1, n, v);
  cout << ans << endl;
  return 0;
}
