Problem: There are N panels arranged in a row in Takahashi's house, numbered 1 through N. The i-th panel has a number A_i written on it. Takahashi is playing by throwing balls at these panels.

Takahashi threw a ball K times. Let the panel hit by a boll in the i-th throw be panel p_i. He set the score for the i-th throw as i \times A_{p_i}.

He was about to calculate the total score for his throws, when he realized that he forgot the panels hit by balls, p_1,p_2,...,p_K. The only fact he remembers is that for every i (1 ≦ i ≦ K-1), 1 ≦ p_{i+1}-p_i ≦ M holds. Based on this fact, find the maximum possible total score for his throws.

Constraints

* 1 ≦ M ≦ N ≦ 100,000
* 1 ≦ K ≦ min(300,N)
* 1 ≦ A_i ≦ 10^{9}

Input

The input is given from Standard Input in the following format:


N M K
A_1 A_2 … A_N


Output

Print the maximum possible total score for Takahashi's throws.

Examples

Input

5 2 3
10 2 8 10 2


Output

56


Input

5 5 2
5 2 10 5 9


Output

28


Input

10 3 5
3 7 2 6 9 4 8 5 1 1000000000


Output

5000000078

Solution (in CPP):

Solution:
#include <cstdio>
#include <iostream>
#include <algorithm>
#include <string>
#include <cstring>
#include <vector>
#include <queue>
#include <set>
#include <map>
#include <cmath>
#include <iomanip>
#include <cassert>
#include <bitset>
#include <deque>
using namespace std;

#define rep(i, n) for (int i=0; i<(n); i++)
#define all(c) (c).begin(), (c).end()
#define uniq(c) c.erase(unique(all(c)), (c).end())
#define index(xs, x) (int)(lower_bound(all(xs), x) - xs.begin())
#define _1 first
#define _2 second
#define pb push_back
#define INF (1LL<<60)
#define MOD 1000000007
typedef pair<long long, long long> P;

struct SlideMin {
  long long *src;
  int right;
  deque<P> deq;
  SlideMin() : src(NULL), right(0) {}
  SlideMin(long long *src) : src(src), right(0) {}
  void add(int x, long long y) {
    while (!deq.empty() && deq.back()._2 >= y) deq.pop_back();
    deq.push_back(P(x, y));
  }
  long long query(int l, int r) {
    while (right <= r) {
      add(right, src[right]);
      right++;
    }
    while (!deq.empty() && deq.front()._1 < l) deq.pop_front();
    if (deq.empty()) return INF;
    return deq.front()._2;
  }
};

int N, M, K;
int A[100000];
long long dp[301][100000];
SlideMin smin[301];

signed main() {
  ios::sync_with_stdio(false); cin.tie(0);
  cin >> N >> M >> K;
  rep(i, N) cin >> A[i];
  rep(k, K+1) rep(i, N) dp[k][i] = INF;
  rep(i, N) dp[0][i] = 0;
  rep(k, K+1) smin[k] = SlideMin(dp[k]);
  dp[1][0] = -A[0];
  rep(k, K) rep(i, N) {
    dp[k+1][i] = min(dp[k+1][i], -(-smin[k].query(i-M, i-1) + 1LL*(k+1)*A[i]));
  }
  long long m = 0;
  rep(i, N) m = max(m, -dp[K][i]);
  cout << m << "\n";
  return 0;
}