A sensor logs one integer energy reading per second. Given a fixed window length k, you want to find the single window of k consecutive readings whose total energy is the largest.
Return that maximum total. Readings may be negative (energy can be drained).
Input format
Line 1: two integers n and k separated by a space, where n is the number of readings and k is the window length.
Line 2: n space-separated integers, the readings in order.
Output format
A single integer: the maximum sum over all contiguous windows of exactly k readings.
Constraints
- 1 ≤ k ≤ n ≤ 100000
- -1000000 ≤ each reading ≤ 1000000
- There is always at least one valid window (since k ≤ n).