#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, t, r;
  cin >> n >> t >> r;
  int arr[n];
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
  }
  if (r > t) {
    cout << "-1";
    return 0;
  }
  map<int, int> mp;
  int sum = 0;
  for (int i = 0; i < n; i++) {
    int w = arr[i];
    int c = 0;
    int s = t;
    w--;
    while (s > 0) {
      if (mp[w] != 0) {
        c++;
      }
      w--;
      s--;
    }
    if (c < r) {
      s = 0;
      int d = r - c;
      w = arr[i] - 1;
      while (d > 0 && s < t) {
        if (mp[w] == 0) {
          mp[w]++;
          sum++;
          d--;
        }
        w--;
        s++;
      }
      if (d != 0) {
        cout << "-1";
        return 0;
      }
    }
  }
  cout << sum;
}
