#include <bits/stdc++.h>
using namespace std;
struct bus {
  double v, st;
  double res;
  int ind;
  bus() {}
  bus(double _v, double _st, int _ind) {
    v = _v;
    st = _st;
    ind = _ind;
  }
  bool operator<(const bus a) const { return st < a.st; }
};
bus b[100006];
double calc(double btime, double v, double a, double d) {
  double t1 = v / a;
  double s1 = (t1 * t1 * a) / 2.0;
  if (s1 > d) {
    return btime + sqrt((2 * d) / a);
  } else
    d -= s1;
  t1 += (d / v);
  return btime + t1;
}
bool f(bus a, bus b) { return a.ind < b.ind; }
int main() {
  int n;
  double a, d;
  cin >> n >> a >> d;
  double x, y;
  for (int i = 0; i < n; i++) {
    cin >> x >> y;
    b[i] = bus(y, x, i);
  }
  sort(b, b + n);
  double curr;
  for (int i = 0; i < n; i++) {
    curr = calc(b[i].st, b[i].v, a, d);
    if (curr < b[i - 1].res)
      b[i].res = b[i - 1].res;
    else
      b[i].res = curr;
  }
  sort(b, b + n, f);
  for (int i = 0; i < n; i++) {
    printf("%.10lf\n", b[i].res);
  }
  return 0;
}
