#include <bits/stdc++.h>
using namespace std;
const int maxn = 100100;
int n, k, z, s[maxn], a[maxn];
int main() {
  int t;
  scanf("%d", &t);
  while (t--) {
    scanf("%d%d%d", &n, &k, &z);
    int ans = 0;
    for (int i = 1; i <= n; ++i) {
      scanf("%d", &a[i]);
      s[i] = s[i - 1] + a[i];
    }
    int mx = 0, tmp = 0;
    for (int i = z; i >= 0; --i) {
      int pos = 1 + k - i * 2;
      if (pos < 1) continue;
      for (int j = tmp + 1; j <= pos; ++j) {
        mx = max(mx, a[j] + a[j + 1]);
      }
      tmp = pos;
      ans = max(ans, s[pos] + mx * i);
    }
    printf("%d\n", ans);
  }
  return 0;
}
