#include <bits/stdc++.h>
const long long INF = 0x3f3f3f3f3f3f3f3f;
long long n, k, x, a[207];
long long memo[207][207][207];
long long go(const long long& cur, const long long& last,
             const long long& left) {
  if (left < 0) return -INF;
  if (cur - last + 1 > k) return -INF;
  if (cur >= n) return 0;
  long long& ret = memo[cur][last][left];
  if (ret != -1) return ret;
  ret = -INF;
  ret = std::max(ret, a[cur] + go(cur + 1, cur + 1, left - 1));
  ret = std::max(ret, go(cur + 1, last, left));
  return ret;
}
int main(void) {
  std::cin >> n >> k >> x;
  for (long long i = 0; i < n; ++i) std::cin >> a[i];
  memset(memo, 0xff, sizeof(memo));
  long long ans = go(0, 0, x);
  if (ans < 0) ans = -1;
  std::cout << ans << "\n";
  return 0;
}
