#include <bits/stdc++.h>
using namespace std;
const int MAX_N = 100030;
const long long MODD = 1000000009;
long long A[MAX_N], DP[MAX_N];
long long n, E, T;
long long f(long long len) {
  if (2 * len >= T) return 2 * len;
  return T;
}
int last;
long long g(int idx) {
  long long& x = DP[idx];
  if (x >= 0) return x;
  for (int i = last; i > idx; i--) {
    long long val = g(i) + f(A[i - 1] - A[idx]);
    if (x == -1 || val < x) {
      x = val;
    } else {
      last = i + 1;
      break;
    }
  }
  return x;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cin >> n >> E >> T;
  last = n;
  for (int i = 0; i < n; i++) cin >> A[i];
  for (int i = 0; i < n; i++) DP[i] = -1;
  for (int i = n - 1; i >= 0; i--) g(i);
  cout << E + g(0) << endl;
  return 0;
}
