#include <bits/stdc++.h>
using namespace std;
const double eps = 0.000001;
int N, A, D;
double timeA[100002];
int main() {
  cin >> N >> A >> D;
  for (int i = 1, T, V; i <= N; ++i) {
    cin >> T >> V;
    double timedo = 1.0 * V / A + 1.0 * (1.0 * D - 1.0 * V / A * V / 2) / V;
    if (1.0 * D - 1.0 * V / A * V / 2 < -eps) timedo = sqrt(1.0 * D * 2 / A);
    if (i != 1 && T + timedo - timeA[i - 1] <= eps)
      timeA[i] = timeA[i - 1];
    else
      timeA[i] = T + timedo;
    cout << fixed << ' ' << setprecision(6) << timeA[i] << '\n';
  }
}
