n,k=map(int,input().split())
p=list(map(int,input().split()))
a=[None]*(n-k+1)
a[0]=sum(p[0:k])
for i in range(1,n-k+1):
    a[i]=a[i-1]-p[i-1]+p[i+k-1]
b=max(a)
c=(b/2)+(0.5*k)
print(c) n,k=map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split k p=list(map(int,input().split())) p list(map(int,input().split())) list map(int,input().split()) map int input().split() ().split () input split a=[None]*(n-k+1) a [None]*(n-k+1) [None] None n-k+1 n-k n k 1 a[0]=sum(p[0:k]) a[0] a 0 sum(p[0:k]) sum p[0:k] p 0:k 0 k for i in range(1,n-k+1):
    a[i]=a[i-1]-p[i-1]+p[i+k-1] i range(1,n-k+1) range 1 n-k+1 n-k n k 1 a[i]=a[i-1]-p[i-1]+p[i+k-1] a[i] a i a[i-1]-p[i-1]+p[i+k-1] a[i-1]-p[i-1] a[i-1] a i-1 i 1 p[i-1] p i-1 i 1 p[i+k-1] p i+k-1 i+k i k 1 b=max(a) b max(a) max a c=(b/2)+(0.5*k) c (b/2)+(0.5*k) b/2 b 2 0.5*k 0.5 k print(c) print c b=max(a) max(a) b c=(b/2)+(0.5*k) (b/2)+(0.5*k) c a=[None]*(n-k+1) [None]*(n-k+1) a k=map(int,input().split()) map(int,input().split()) k p=list(map(int,input().split())) list(map(int,input().split())) p n,k=map(int,input().split()) map(int,input().split()) n
n,k=map(int,input().split())
p=list(map(int,input().split()))
a=[None]*(n-k+1)
a[0]=sum(p[0:k])
for i in range(1,n-k+1):
    a[i]=a[i-1]-p[i-1]+p[i+k-1]
b=max(a)
c=(b/2)+(0.5*k)
print(c)