n, k = list(map(int, input().split()))
exp = list(map(lambda x: (1+int(x))/2, input().split()))

c = sum(exp[:k])
cmax = c

for i in range(n-k):
    c -= exp[i]
    c += exp[i+k]

    if c > cmax:
        cmax = c

print(cmax) n, k = list(map(int, input().split())) n list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split k exp = list(map(lambda x: (1+int(x))/2, input().split())) exp list(map(lambda x: (1+int(x))/2, input().split())) list map(lambda x: (1+int(x))/2, input().split()) map lambda x: (1+int(x))/2 (1+int(x))/2 1+int(x) 1 int(x) int x 2 x input().split() ().split () input split c = sum(exp[:k]) c sum(exp[:k]) sum exp[:k] exp :k k cmax = c cmax c for i in range(n-k):
    c -= exp[i]
    c += exp[i+k]

    if c > cmax:
        cmax = c i range(n-k) range n-k n k c -= exp[i] c exp[i] exp i c += exp[i+k] c exp[i+k] exp i+k i k if c > cmax:
        cmax = c c > cmax c cmax cmax = c cmax c print(cmax) print cmax exp = list(map(lambda x: (1+int(x))/2, input().split())) list(map(lambda x: (1+int(x))/2, input().split())) exp c = sum(exp[:k]) sum(exp[:k]) c c += exp[i+k] exp[i+k] c cmax = c c cmax k = list(map(int, input().split())) list(map(int, input().split())) k cmax = c c cmax c -= exp[i] exp[i] c n, k = list(map(int, input().split())) list(map(int, input().split())) n
n, k = list(map(int, input().split()))
exp = list(map(lambda x: (1+int(x))/2, input().split()))

c = sum(exp[:k])
cmax = c

for i in range(n-k):
    c -= exp[i]
    c += exp[i+k]

    if c > cmax:
        cmax = c

print(cmax)