#include <bits/stdc++.h>
using namespace std;
const int lzw = 200 + 3;
int n, k, m, a[lzw];
long long f[lzw][lzw], ans;
int main() {
  scanf("%d%d%d", &n, &k, &m);
  for (register int i = 1; i <= n; i++) scanf("%d", &a[i]);
  if (m < n / k) {
    printf("-1\n");
    return 0;
  }
  memset(f, 128, sizeof(f));
  for (register int i = 0; i <= k - 1; i++) f[i][0] = 0;
  for (register int j = 1; j <= m; j++) {
    for (register int i = 1; i <= n; i++) {
      for (register int l = max(1, i - k + 1); l <= i; l++) {
        f[i][j] = max(f[i][j], f[l - 1][j - 1] + a[l]);
      }
    }
  }
  printf("%lld\n", f[n][m]);
  return 0;
}
