#include <bits/stdc++.h>
using namespace std;
const int MAX = 300000;
bool downwards(int a, int b){
    return a>b;
}
long long n, k, a[MAX], sum[MAX];
int main(){
ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
cin>>n>>k;
for(int i=0;i<n;i++){
    cin>>a[i];
    if(i==0){
        sum[i]=a[i];
    }else{
        sum[i]=sum[i-1]+a[i];
    }
}
double res=0;
for(int j=k;j<k+100 and j<=n;j++){

    long long bestSum=sum[j-1];
    for(int i=j;i<n;i++){
        if(sum[i]-sum[i-j]>bestSum){
            bestSum=sum[i]-sum[i-j];
        }
    }
    vector <int> bestStart;
    for(int i=j;i<n;i++){
        if(sum[i]-sum[i-j]==bestSum){
            bestStart.push_back(i-j+1);
        }
    }
    double finalAns=0;
    for(int z=0;z<bestStart.size();z++){
        double averageToBeat = (double)bestSum / j;
        double bestLowerAverage=-1, bestUpperAverage=-1;
        int num=1, bestLowerNum=0, bestUpperNum=0;
        long long currSum=0;
        for(int i=bestStart[z]-1;i>=0;i--){
            if(num>=j){
               // break;
            }
            currSum = currSum + a[i];
            if((double)currSum / num >bestLowerAverage){
                bestLowerAverage = (double)currSum / num;
                bestLowerNum = num;
            }
            num++;
        }
        num=1;
        currSum=0;
        for(int i=bestStart[z]+j;i<n;i++){
            if(num>=j){
                //break;
            }
            currSum = currSum + a[i];
            if((double)currSum / num >bestUpperAverage){
                bestUpperAverage = (double)currSum / num;
                bestUpperNum = num;
            }
            num++;
        }
        int finalNum=j;
        double ans = averageToBeat;
        if(bestLowerAverage>bestUpperAverage){
            if(bestLowerAverage>averageToBeat){
                finalNum += bestLowerNum;
                ans = (bestLowerNum*bestLowerAverage + j*averageToBeat)/(finalNum);
            }
            if(bestUpperAverage>ans){
                ans = (ans*finalNum + bestUpperNum*bestUpperAverage)/(finalNum+bestUpperNum);
            }
        }else{
            if(bestUpperAverage>averageToBeat){
                finalNum += bestUpperNum;
                ans = (bestUpperNum*bestUpperAverage + j*averageToBeat)/(finalNum);
            }
            if(bestLowerAverage>ans){
                ans = (ans*finalNum + bestLowerNum*bestLowerAverage)/(finalNum+bestLowerNum);
            }
        }
        if(ans>finalAns){
            finalAns=ans;
        }
    }
    if(finalAns>res){
        res=finalAns;
    }
}
cout<<setprecision(10)<<res;
return 0;
}
