#include <cstdio>
#include <algorithm>
typedef long long ll;

int n,L,t,v,l=1,r=0;
ll qv[500005],Aw;
double qt[500005],Ns;

int main()
{
    //freopen("in.txt","r",stdin);
    for(scanf("%d%d",&n,&L);n--;)
    {
        scanf("%d%d",&t,&v);
        while(Aw+v>L)
        {
            ll Po=std::min(qv[l],Aw+v-L);
            qv[l]-=Po,Aw-=Po,Ns-=qt[l]*Po;
            if(!qv[l])++l;
        }
        Aw+=v,Ns+=(ll)t*v,qv[++r]=v,qt[r]=t;
        for(;l<r&&qt[r-1]>qt[r];--r)qt[r-1]=(qt[r-1]*qv[r-1]+qt[r]*qv[r])/(qv[r-1]+qv[r]),qv[r-1]+=qv[r];
        printf("%.7f\n",Ns/L);
    }
    return 0;
}
