#include <bits/stdc++.h>
using namespace std;
vector<int> adj[300105], new_adj[300105];
int xMove[] = {0, 1, 0, -1, 1, 1, -1, -1, 2, 2, -2, -2, 1, 1, -1, -1};
int yMove[] = {1, 0, -1, 0, 1, -1, 1, -1, 1, -1, 1, -1, 2, -2, 2, -2};
void clr(int n) {
  for (int i = 0; i < n + 2; i++) adj[i].clear();
}
long long int b[205], n, k, x;
long long int dp[205][205][205];
long long int solve(int i, int x, int last) {
  if (i == n) return 0;
  if (dp[i][x][last] != -1) return dp[i][x][last];
  assert(n - i >= x);
  long long int ans = -1;
  if (last < k and n - i > x) ans = max(ans, solve(i + 1, x, last + 1));
  if (x > 0 and (n - i - 1) / k <= x - 1) {
    long long int cur = solve(i + 1, x - 1, 1);
    if (cur != -1) ans = max(ans, b[i] + cur);
  }
  assert(ans != -1);
  return dp[i][x][last] = ans;
}
int main() {
  cin.tie(0), cout.tie(0);
  ios_base::sync_with_stdio(0);
  int TC = 1;
  int q, m, e, t;
  {
    cin >> n >> k >> x;
    for (int i = 0; i < n; i++) {
      cin >> b[i];
    }
    memset(dp, -1, sizeof dp);
    if (n / k > x)
      cout << -1 << '\n';
    else
      cout << solve(0, x, 1) << '\n';
  }
  return 0;
}
