#include <bits/stdc++.h>
using namespace std;
vector<int> v;
int cnt[300006];
int vis[300006];
int done[300006];
int main() {
  int m, t, r, x;
  int mid = 300006 >> 1;
  cin >> m >> t >> r;
  for (int i = 0; i < m; i++) {
    cin >> x;
    x += mid;
    v.push_back(x);
    vis[x] = 1;
  }
  bool ok = 1;
  int res = 0;
  int sofar = 0;
  for (int j = mid; j < 300006 && ok; j++) {
    if (vis[j]) {
      if (sofar < r) {
        int dif = r - sofar;
        int c = 0;
        for (int i = 1;; i++) {
          int nw = j - i;
          int nxt = nw + t;
          if (nxt < j) {
            ok = 0;
            break;
          }
          if (done[nw]) continue;
          done[nw] = 1;
          cnt[nxt] = -1;
          res++;
          sofar++;
          if (sofar >= r) break;
        }
      }
    }
    sofar += cnt[j];
    if (j > v.back()) break;
  }
  if (ok)
    cout << res << endl;
  else
    cout << -1 << endl;
  return 0;
}
