#include <bits/stdc++.h>
using namespace std;
int n;
double a, d;
struct DD {
  double t;
  double v;
  int id;
} bus[100010];
struct answer {
  double t;
  int id;
} ans[100010];
int cmp(const DD& a, const DD& b) { return a.t < b.t; }
int cmpt(const answer& a, const answer& b) { return a.id < b.id; }
int main() {
  scanf("%d%lf%lf", &n, &a, &d);
  for (int i = 0; i < n; i++) {
    scanf("%lf%lf", &bus[i].t, &bus[i].v);
    bus[i].id = i;
  }
  sort(bus, bus + n, cmp);
  for (int i = 0; i < n; i++) {
    double x = bus[i].v / a;
    if (a * x * x / 2 > d) {
      ans[i].t = bus[i].t + sqrt(2 * d / a);
    } else {
      ans[i].t = bus[i].t + x + (d - bus[i].v * x / 2) / bus[i].v;
    }
    if (i) {
      ans[i].t = ((ans[i].t) > (ans[i - 1].t) ? (ans[i].t) : (ans[i - 1].t));
    }
    ans[i].id = bus[i].id;
  }
  sort(ans, ans + n, cmpt);
  for (int i = 0; i < n; i++) {
    printf("%.10lf\n", ans[i].t);
  }
}
