#include <bits/stdc++.h>

const int MAXN = 500010;
typedef double db;
int n, L, vs[MAXN];
db ts[MAXN], tov;
int b, e;
int main() {
	std::ios_base::sync_with_stdio(false), std::cin.tie(0);
	std::cout << std::fixed << std::setprecision(8);
	std::cin >> n >> L; int tl = 0;
	for (int i = b = 1, v; i <= n; ++i) {
		db t; std::cin >> t >> v; tl += v; tov += v * t;
		while (tl > L) {
			int res = std::min(tl - L, vs[b]);
			tov -= ts[b] * res; vs[b] -= res; tl -= res;
			if (!vs[b]) ++b;
		}
		std::cout << tov / L << '\n';
		while (b <= e && t <= ts[e])
			t = (t * v + ts[e] * vs[e]) / (v + vs[e]), v += vs[e], --e;
		++e; ts[e] = t, vs[e] = v;
	}
	return 0;
}
