#include <bits/stdc++.h>
using namespace std;
long long n, k, z, a[1001000], dp[202][202][202];
long long solve(int pos, int lerigo, int lft) {
  if (lerigo < 0 || lft < 0) return -1000000000000000LL;
  if (pos == n && lft == 0) return 0;
  if (pos == n) return -1000000000000000LL;
  long long &x = dp[pos][lerigo][lft];
  if (x != -1) return x;
  x = max(solve(pos + 1, lerigo - 1, lft),
          solve(pos + 1, k - 1, lft - 1) + a[pos]);
  return x;
}
int main() {
  scanf("%lld %lld %lld", &n, &k, &z);
  memset(dp, -1, sizeof dp);
  for (int i = 0; i < n; i++) {
    scanf("%lld", &a[i]);
  }
  printf("%lld\n", max(-1LL, solve(0, k - 1, z)));
  return 0;
}
