N,K=map(int,input().split())
p=list(map(int,input().split()))
sum=0
v=[]
for i in range(K):
    sum+=p[i]
v.append(sum)
for i in range(K,N):
    sum+=p[i]
    sum-=p[i-K]
    v.append(sum)
M=0
for i in range(N+1-K):
    M=max(M,v[i])
print((M+K)/2) 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 sum=0 sum 0 v=[] v [] for i in range(K):
    sum+=p[i] i range(K) range K sum+=p[i] sum p[i] p i v.append(sum) v.append v append sum for i in range(K,N):
    sum+=p[i]
    sum-=p[i-K]
    v.append(sum) i range(K,N) range K N sum+=p[i] sum p[i] p i sum-=p[i-K] sum p[i-K] p i-K i K v.append(sum) v.append v append sum M=0 M 0 for i in range(N+1-K):
    M=max(M,v[i]) i range(N+1-K) range N+1-K N+1 N 1 K M=max(M,v[i]) M max(M,v[i]) max M v[i] v i print((M+K)/2) print (M+K)/2 M+K M K 2 sum+=p[i] p[i] sum v=[] [] v sum=0 0 sum M=0 0 M N,K=map(int,input().split()) map(int,input().split()) N K=map(int,input().split()) map(int,input().split()) K sum-=p[i-K] p[i-K] sum sum+=p[i] p[i] sum p=list(map(int,input().split())) list(map(int,input().split())) p M=max(M,v[i]) max(M,v[i]) M
N,K=map(int,input().split())
p=list(map(int,input().split()))
sum=0
v=[]
for i in range(K):
    sum+=p[i]
v.append(sum)
for i in range(K,N):
    sum+=p[i]
    sum-=p[i-K]
    v.append(sum)
M=0
for i in range(N+1-K):
    M=max(M,v[i])
print((M+K)/2)
