#include <bits/stdc++.h>
using namespace std;
int n;
double ans, a, d, t, v, ansl = 0;
;
int main() {
  cin >> n >> a >> d;
  for (int i = n; i; --i) {
    cin >> t >> v;
    double t1 = v / a, s1 = v * v / 2 / a, s2 = d - s1, t2 = s2 / v;
    if (s1 > d)
      ans = sqrt(2 * d / a) + t;
    else
      ans = t1 + t2 + t;
    if (ans < ansl)
      printf("%0.10f\n", ansl);
    else {
      printf("%0.10f\n", ans);
      ansl = ans;
    }
  }
  return 0;
}
