#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:3677720")
using namespace std;
int main() {
  int m, t, r;
  scanf("%d %d %d", &m, &t, &r);
  map<int, int> tmp;
  set<int> is_switch;
  vector<int> w(m);
  int ans = 0;
  for (int i = 0; i < m; i++) {
    scanf("%d", &w[i]);
  }
  for (int i = w[0] - 1; i >= w[0] - r; i--) {
    is_switch.insert(i);
    for (int j = i + 1; j <= i + t; j++) tmp[j]++;
  }
  ans += r;
  if (tmp[w[0]] < r) {
    puts("-1");
    return 0;
  }
  for (int i = 1; i < m; i++) {
    if (tmp[w[i]] >= r)
      continue;
    else {
      for (int j = w[i] - 1; j >= w[i] - t; j--) {
        if (tmp[w[i]] == r) continue;
        if (!is_switch.count(j)) {
          is_switch.insert(j);
          for (int k = j + 1; k <= j + t; k++) {
            tmp[k]++;
          }
          ans++;
        }
      }
      if (tmp[w[i]] < r) {
        puts("-1");
        return 0;
      }
    }
  }
  cout << ans;
  return 0;
}
