#include <bits/stdc++.h>
using namespace std;
inline void OPEN(const string &s) {
  freopen((s + ".in").c_str(), "r", stdin);
  freopen((s + ".out").c_str(), "w", stdout);
}
struct point {
  double x, y;
  point() { x = y = 0; }
  point(double x, double y) : x(x), y(y) {}
};
struct segment {
  point p1, p2;
  segment() { p1 = p2 = point(0, 0); }
  segment(point p1, point p2) : p1(p1), p2(p2) {}
};
point operator-(const point &p1, const point &p2) {
  return point(p1.x - p2.x, p1.y - p2.y);
}
point operator+(const point &p1, const point &p2) {
  return point(p1.x + p2.x, p1.y + p2.y);
}
point operator*(const point &p, const double &s) {
  return point(p.x * s, p.y * s);
}
point operator/(const point &p, const double &s) { return p * (1. / s); }
bool operator<(const point &p1, const point &p2) {
  if (p1.x != p2.x) return p1.x < p2.x;
  return p1.y < p2.y;
}
bool operator==(const point &p1, const point &p2) {
  return fabs(p1.x - p2.x) < 1e-9 && fabs(p1.y - p2.y) < 1e-9;
}
double dist(const point &p) { return sqrt(((p.x) * (p.x)) + ((p.y) * (p.y))); }
double dist(const point &p1, const point &p2) {
  return sqrt(((p1.x - p2.x) * (p1.x - p2.x)) +
              ((p1.y - p2.y) * (p1.y - p2.y)));
}
double cross(const point &p1, const point &p2) {
  return p1.x * p2.y - p1.y * p2.x;
}
double distToLine(const point &p, const segment &s) {
  return fabs(cross(s.p1 - p, s.p2 - p)) / dist(s.p1, s.p2);
}
double x, y, yl, yh, yw, xb, yb, r;
int check(double xw) {
  double xlo = 2. * xw - xb;
  double m = (yb - yw) / (xlo - xw);
  double yy = yw - m * xw;
  if (yy < yl) return 0;
  return 1;
}
int check2(double xw) {
  double xlo = 2. * xw - xb;
  double m = (yb - yw) / (xlo - xw);
  double yy = yw - m * xw;
  segment seg(point(0, yy), point(xw, yw));
  point p(0, yh);
  if (distToLine(p, seg) < r) return 0;
  return 1;
}
int main() {
  scanf("%lf %lf %lf %lf %lf %lf", &yl, &yh, &yw, &xb, &yb, &r);
  yw -= r;
  yl += r;
  double le = 0., ri = xb - 1e-9;
  for (int bs = 0; bs < 1000000 && le < ri; bs++) {
    double piv = (le + ri + 1e-9) / 2.;
    if (check(piv))
      le = piv;
    else
      ri = piv - 1e-9;
  }
  if (check(le) == 1 && check2(le) == 1) {
    printf("%.10lf\n", le);
  } else {
    printf("-1\n");
  }
  return 0;
}
