n, k = map(int, input().split())
a = [(int(i) + 1)/2 for i in input().split()]
ans = 0
s = sum(a[:k])
ans = s
for i in range(k, n):
	s -= a[i - k]
	s += a[i]
	ans = max(ans, s)
print(ans) n, k = map(int, input().split()) n map(int, input().split()) map int input().split() ().split () input split k (int(i) + 1)/2 for i in input().split() for i in input().split() i input().split() ().split () input split for i in input().split() (int(i) + 1)/2 int(i) + 1 int(i) int i 1 2 a = [(int(i) + 1)/2 for i in input().split()] a [(int(i) + 1)/2 for i in input().split()] ans = 0 ans 0 s = sum(a[:k]) s sum(a[:k]) sum a[:k] a :k k ans = s ans s for i in range(k, n):
	s -= a[i - k]
	s += a[i]
	ans = max(ans, s) i range(k, n) range k n s -= a[i - k] s a[i - k] a i - k i k s += a[i] s a[i] a i ans = max(ans, s) ans max(ans, s) max ans s print(ans) print ans s += a[i] a[i] s a = [(int(i) + 1)/2 for i in input().split()] [(int(i) + 1)/2 for i in input().split()] a ans = max(ans, s) max(ans, s) ans k = map(int, input().split()) map(int, input().split()) k ans = s s ans n, k = map(int, input().split()) map(int, input().split()) n s = sum(a[:k]) sum(a[:k]) s s -= a[i - k] a[i - k] s ans = 0 0 ans
n, k = map(int, input().split())
a = [(int(i) + 1)/2 for i in input().split()]
ans = 0
s = sum(a[:k])
ans = s
for i in range(k, n):
	s -= a[i - k]
	s += a[i]
	ans = max(ans, s)
print(ans)