#include <bits/stdc++.h>
using namespace std;
int countbit(int n) { return (n == 0) ? 0 : (1 + countbit(n & (n - 1))); }
int lowbit(int n) { return (n ^ (n - 1)) & n; }
const int Mod = 1000000007;
int n;
double a, d;
int main() {
  scanf("%d%lf%lf", &n, &a, &d);
  double lastTime = -1.00;
  for (int i = 0; i < n; ++i) {
    double t, v;
    scanf("%lf%lf", &t, &v);
    if (0.5 * v * v / a - 1e-10 > d) {
      double tm = sqrt(2 * d / a) + t;
      if (lastTime - 1e-10 > tm) tm = lastTime;
      printf("%.8f\n", tm);
      lastTime = tm;
    } else {
      double tm = d / v - v / 2 / a + v / a + t;
      if (lastTime - 1e-10 > tm) tm = lastTime;
      printf("%.8f\n", tm);
      lastTime = tm;
    }
  }
  return 0;
}
