#include <bits/stdc++.h>
using namespace std;
double Y1, Y2, w, x, y, r;
int main() {
  scanf("%lf%lf%lf%lf%lf%lf", &Y1, &Y2, &w, &x, &y, &r);
  w -= r;
  double s = 0, e = x - 1e-10, ans = -1;
  for (int i = 0; i < 50; ++i) {
    double m = (s + e) / 2;
    double dx = m - x, dy = w - y;
    double p = -1.0 * dy / dx;
    double DX = r / sqrt(1 + (-1.0 / p) * (-1.0 / p));
    double DY = (-1.0 / p) * DX;
    if (DX > 0.0) DX *= -1, DY *= -1;
    double q1 = w - r - p * (m);
    double q2 = w + DY - p * (m + DX);
    if (q2 > Y2 + 1e-10)
      s = m;
    else if (q1 < Y1 - 1e-10)
      e = m;
    else {
      ans = m;
      break;
    }
  }
  if (ans > 0.0)
    printf("%.10lf", ans);
  else
    printf("-1");
  return 0;
}
