#include <bits/stdc++.h>
const double pi = acos(-1.0);
int main() {
  int n;
  double s, f, r, v, t;
  scanf("%d %lf %lf", &n, &r, &v);
  double p = 2 * pi * r;
  double tp = p / v;
  while (n--) {
    scanf("%lf %lf", &s, &f);
    double x = f - s;
    double cyc = floor(x / p);
    double rem = (x - cyc * p) / r / 2;
    double lo = 0, hi = pi;
    for (int i = 0; i < 60; ++i) {
      double mid = (lo + hi) / 2;
      if (mid + sin(mid) < rem)
        lo = mid;
      else
        hi = mid;
    }
    t = cyc * tp + 2 * lo * r / v;
    printf("%.8lf\n", t);
  }
}
