#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int n, m, ans, p = 0, sum = -1;
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> m;
  long long int arr[n];
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
    if (i < m)
      p += arr[i];
    else if (i >= m) {
      if (p <= sum || sum == -1) ans = i + 1, sum = p;
      p = p - arr[i - m] + arr[i];
    }
  }
  if (p <= sum || sum == -1) ans = n + 1;
  cout << ans - m << endl;
  return 0;
}
