#include <bits/stdc++.h>
using namespace std;
int n, a, d;
pair<pair<int, int>, int> b[1000005];
double c[1000005];
double bs(int vi) {
  double s = 0, e = vi, md;
  for (int i = 0; i <= 200 && s <= e; i++) {
    md = s + (e - s) / 2.0;
    double ss = md / a;
    double ssd = 0.5 * a * ss * ss;
    if (fabs(ssd - d) <= 1e-6)
      return ss;
    else if (ssd > d) {
      e = md - 1e-12;
    } else
      s = md + 1e-12;
  }
  assert(false);
}
double calc(double vi) {
  double s = vi / a;
  double sd = 0.5 * a * s * s;
  if (fabs(d - sd) <= 1e-12) {
    return s;
  } else if (sd > d) {
    return bs(vi);
  } else {
    return s + (d - sd) / vi;
  }
}
int main() {
  scanf("%d%d%d", &n, &a, &d);
  for (int i = 0; i < n; i++) {
    scanf("%d%d", &b[i].first.first, &b[i].first.second);
    b[i].second = i;
  }
  sort(b, b + n);
  double mx = 0;
  for (int i = 0; i < n; i++) {
    double ans = b[i].first.first + calc(b[i].first.second);
    if (ans > mx) mx = ans;
    c[b[i].second] = mx;
  }
  for (int i = 0; i < n; i++) {
    printf("%.10lf\n", c[i]);
  }
  return 0;
}
