#include <bits/stdc++.h>
using namespace std;
const double pi = acos(-1);
const double eps = 1e-10;
int read() {
  char ch = getchar();
  int data = 0;
  while (ch < '0' || ch > '9') ch = getchar();
  do {
    data = data * 10 + ch - '0';
    ch = getchar();
  } while (ch >= '0' && ch <= '9');
  return data;
}
int main() {
  int n;
  double r, v, re, t, ans, s, f, w;
  cin >> n >> r >> v;
  w = v / r;
  while (n--) {
    scanf("%lf%lf", &s, &f);
    re = fmod(f - s, 2 * pi * r);
    ans = (f - s - re) / v;
    re = re * 0.5;
    double l = 0, rr = 2 * pi / w, mid;
    for (int i = 1; i <= 2333; i++) {
      mid = (l + rr) * 0.5;
      if (pi * r + re < r * (w * mid - sin(w * mid)))
        rr = mid;
      else
        l = mid;
      if (l + eps >= rr) break;
    }
    ans += (mid - pi * r / v) * 2.0;
    printf("%.15f\n", ans);
  }
}
