#include <bits/stdc++.h>
using namespace std;
int main() {
  ios ::sync_with_stdio(0);
  cin.tie(0);
  cout << (fixed) << setprecision(9);
  int n;
  double R, v;
  while (cin >> n >> R >> v) {
    while (n--) {
      double s, f, len;
      cin >> s >> f;
      len = f - s;
      if (len < 0) len = -len;
      double each = 2 * acos((double)-1.0) * R;
      double cnt = floor(len / each);
      len -= each * cnt;
      double l = 0;
      double r = len * 0.5 + R;
      for (int turn = 0, _a = (60); turn < _a; ++turn) {
        double mid = (l + r) / 2.0;
        if (mid + R * sin(mid / R) >= len * 0.5) {
          r = mid;
        } else
          l = mid;
      }
      cout << ((l + r) + each * cnt) / v << '\n';
    }
  }
}
