题目描述
Vishal loves running. He often visits his favourite Nehru Park and runs for very long distances. On one such visit he found that the number of girls in the park was unusually high. Now he wants to use this as an opportunity to impress a large number of girls with his awesome speed.
The track on which he runs is an $\text{N}$ kilometres long straight path. There are $\mathbf{a_{i}}$ girls standing within the $\text{ith}$ kilometre of this path. A girl will be impressed only if Vishal is running at his maximum speed when he passes by her. But he can run at his best speed only for a single continuous stretch of $\text{K}$ kilometres. Now Vishal wants to know what is the maximum number of girls that he can impress.
------ Input ------
First line of the input contains the number of testcases $\text{T}$.
For each test case,
First line contains two space-separated integers $\text{N}$ and $\text{K}$, the length of the track and the maximum distance he can run at his best speed.
Second line contains N space-separated integers, the number of girls within each kilometre of the track.
------ Output ------
For each test case print one line containing an integer, denoting the maximum number of girls Vishal can impress.
------ Constraints ------
$1 ≤ \text{T} ≤ 10$
$1 ≤ \text{K} ≤ \text{N} ≤ 100$
$1 ≤ \mathbf{a_{i}} ≤ 100$
----- Sample Input 1 ------
1
7 2
2 4 8 1 2 1 8
----- Sample Output 1 ------
12
----- explanation 1 ------
He can impress 4+8=12 girls if he runs at his best speed between the 2nd and the 3rd kilometre, inclusive.
输入格式
见题面
输出格式
见题面