#include <bits/stdc++.h>

#define fr first
#define sc second
#define mk make_pair

using namespace std;

int n;
double t, v, l;
deque<pair<double, double> > dq;

int main()
{
    cin >> n >> l;
    for(int i = 1; i <= n; i++)
    {
        double a, b;
        cin >> a >> b;
        if(b == l)
        {
            t = v = 0;
            dq.clear();
        }
        while(v + b > l && dq.size() != 0)
        {
            double t1 = dq.front().fr;
            double v1 = min(dq.front().sc, v + b - l);

            t = (t * v - t1 * v1) / (v - v1);
            v = v - v1;

            if(v1 == dq.front().sc)
                dq.pop_front();
            else
            {
                dq.front().sc -= v1;
                break;
            }
        }

        t = (t * v + a * b) / (v + b);
        v = v + b;

        cout << fixed << setprecision(6) << t << endl;

        while( dq.size() != 0)
        {
            //cout << "&";
            double t1 = dq.back().fr;
            double v1 = dq.back().sc;

            if(t1 < a)
                break;

            a = (a * b + t1 * v1) / (v1 + b);
            b = v1 + b;
            dq.pop_back();
        }
        dq.push_back(mk(a, b));
    }
    return 0;
}
