#include <bits/stdc++.h>
using std::bitset;
using std::sort;
using std::swap;
const int N = 155;
int f[2][N][N * N], a[N], p = 0, q = 1, n, m, s, ans;
inline int read() {
  int c = getchar(), t = 0;
  for (; c < 48 || 57 < c; c = getchar())
    ;
  do t = (t << 3) + (t << 1) + c - 48, c = getchar();
  while (47 < c && c < 58);
  return t;
}
inline int min(int x, int y) {
  x -= y;
  return y + (x & (x >> 31));
}
int main() {
  n = read();
  m = read();
  s = read();
  for (int i = 1; i <= n; ++i) a[i] = read();
  if (s >= (n * (n - 1)) >> 1) {
    sort(a + 1, a + n + 1);
    s = 0;
    for (int i = 1; i <= m; ++i) s += a[i];
    printf("%d\n", s);
    return 0;
  }
  memset(f[0], 63, sizeof(f[0]));
  f[0][0][0] = 0;
  for (int i = 1; i <= n; ++i) {
    p ^= 1;
    q ^= 1;
    memset(f[p], 63, sizeof(f[p]));
    for (int j = 0; j <= m; ++j)
      for (int k = 0; k <= s; ++k) f[p][j][k] = min(f[p][j][k], f[q][j][k]);
    for (int j = 1; j <= m; ++j)
      for (int k = i - j; k <= s; ++k)
        f[p][j][k] = min(f[p][j][k], f[q][j - 1][k - i + j] + a[i]);
  }
  ans = f[p][m][0];
  for (int i = 1; i <= s; ++i) ans = min(ans, f[p][m][i]);
  printf("%d\n", ans);
  return 0;
}
