Problem: A lot of people dream of convertibles (also often called cabriolets). Some of convertibles, however, don't have roof at all, and are vulnerable to rain. This is why Melon Ask, the famous inventor, decided to create a rain protection mechanism for convertibles.

The workplace of the mechanism is a part of plane just above the driver. Its functional part consists of two rails with sliding endpoints of a piece of stretching rope. For the sake of simplicity we can consider this as a pair of parallel segments in a plane with the rope segment, whose endpoints we are free to choose as any points on these rails segments.

<image>

The algorithmic part of the mechanism detects each particular raindrop and predicts when and where it reaches the plane. At this exact moment the rope segment must contain the raindrop point (so the rope adsorbs the raindrop).

You are given the initial position of the rope endpoints and all information about raindrops. You are to choose the minimal possible speed v of the endpoints sliding (both endpoints can slide in any direction along their segments independently of each other) in such a way that it is possible to catch all raindrops moving both endpoints with speed not greater than v, or find out that it's impossible no matter how high the speed is.

Input

The first line contains three integers n, w and h (1 ≤ n ≤ 10^5, 1≤ w, h ≤ 10^3), meaning that there are n raindrops, and two rails are represented as segments connecting (0, 0) and (w, 0) and connecting (0, h) and (w, h).

The second line contains two integers e_1 and e_2, meaning that the initial (that is, at the moment t = 0) positions of the endpoints are (e_1, 0) and (e_2, h) (0≤ e_1, e_2≤ w).

The i-th of the following n lines contains three integers t_i, x_i and y_i (1≤ t_i≤ 10^5, 0≤ x_i ≤ w, 0 < y_i < h) meaning that the i-th raindrop touches the plane at the point (x_i, y_i) at the time moment t_i. It is guaranteed that t_i ≤ t_{i+1} for all valid i.

Output

If it is impossible to catch all raindrops, print -1.

Otherwise, print the least possible maximum speed of the rope endpoints for which it is possible to catch them all. Your answer is considered correct if the absolute or relative error doesn't exceed 10^{-4}.

Formally, let your answer be a, and the jury's answer be b. Your answer is considered correct if \frac{|a - b|}{max{(1, |b|)}} ≤ 10^{-4}.

Examples

Input

3 5 5
0 0
1 1 4
2 2 4
3 3 4


Output

1.0000000019


Input

2 5 5
0 0
2 4 1
3 1 4


Output

2.1428571437


Input

3 5 5
0 0
1 2 1
1 3 3
1 4 2


Output

-1

Note

That is how one can act in the first sample test:

<image>

Here is the same for the second:

<image>

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
struct fastio {
  char s[100000];
  int it, len;
  fastio() { it = len = 0; }
  inline char get() {
    if (it < len) return s[it++];
    it = 0;
    len = fread(s, 1, 100000, stdin);
    if (len == 0)
      return EOF;
    else
      return s[it++];
  }
  bool notend() {
    char c = get();
    while (c == ' ' || c == '\n') c = get();
    if (it > 0) it--;
    return c != EOF;
  }
} _buff;
inline long long getnum() {
  long long r = 0;
  bool ng = 0;
  char c;
  c = _buff.get();
  while (c != '-' && (c < '0' || c > '9')) c = _buff.get();
  if (c == '-') ng = 1, c = _buff.get();
  while (c >= '0' && c <= '9') r = r * 10 + c - '0', c = _buff.get();
  return ng ? -r : r;
}
template <class T>
inline void putnum(T x) {
  if (x < 0) putchar('-'), x = -x;
  register short a[20] = {}, sz = 0;
  while (x) a[sz++] = x % 10, x /= 10;
  if (sz == 0) putchar('0');
  for (int i = sz - 1; i >= 0; i--) putchar('0' + a[i]);
}
inline char getreal() {
  char c = _buff.get();
  while (c <= 32) c = _buff.get();
  return c;
}
long long qpow(long long x, long long k) {
  return k == 0 ? 1
                : 1ll * qpow(1ll * x * x % mod, k >> 1) * (k & 1 ? x : 1) % mod;
}
const double eps = 1e-7;
const double pi = acos(-1);
bool is0(double x) { return x > -eps && x < eps; }
struct point {
  double x, y;
  point(double _x = 0, double _y = 0) {
    x = _x;
    y = _y;
  }
  point operator+(const point &t) const { return point(x + t.x, y + t.y); }
  point operator-(const point &t) const { return point(x - t.x, y - t.y); }
  point operator*(const point &t) const {
    return point(x * t.x - y * t.y, x * t.y + y * t.x);
  }
  point operator*(const double &t) const { return point(x * t, y * t); }
  point operator/(const double &t) const { return point(x / t, y / t); }
  point operator-() const { return point(-x, -y); }
  double len() const { return sqrt(x * x + y * y); }
  double sqrl() const { return x * x + y * y; }
  point operator/(const point &t) const {
    return point(x * t.x + y * t.y, -x * t.y + y * t.x) / t.len() / t.len();
  }
  double det(const point &t) const { return x * t.y - y * t.x; }
  double dot(const point &t) const { return x * t.x + y * t.y; }
  double len2() const { return x * x + y * y; }
  point unit() const { return (*this) / len(); }
  bool operator<(const point &t) const {
    return is0(x - t.x) ? (is0(y - t.y) ? 0 : y < t.y) : x < t.x;
  }
  bool operator==(const point &t) const { return is0(x - t.x) && is0(y - t.y); }
  bool operator!=(const point &t) const {
    return !is0(x - t.x) || !is0(y - t.y);
  }
  void out() const {
    if (0) cout << x << "," << y << endl;
  }
  double rad() const { return atan2(y, x); }
  point conj() const { return point(x, -y); }
};
bool cmpwithangle(point x, point y) { return x.rad() < y.rad(); }
bool parallel(const point &px, const point &py, const point &qx,
              const point &qy) {
  return is0((px - py).det(qx - qy));
}
point intersection(const point &px, const point &py, const point &qx,
                   const point &qy) {
  double t = -(px - qx).det(qy - qx) / (py - px).det(qy - qx);
  return px + (py - px) * t;
}
point intersection(const pair<point, point> &p, const pair<point, point> &q) {
  return intersection(p.first, p.second, q.first, q.second);
}
vector<int> construct_ch(const vector<point> &a, int coef) {
  vector<int> s;
  for (int i = 0; i < a.size(); i++) {
    int sz = s.size();
    while (sz >= 2 &&
           (a[i] - a[s[sz - 2]]).det(a[s[sz - 1]] - a[s[sz - 2]]) * coef <
               eps) {
      s.pop_back();
      sz--;
    }
    s.push_back(i);
  }
  return s;
}
vector<int> construct_chull(const vector<point> &a) {
  vector<int> h1 = construct_ch(a, -1), h2 = construct_ch(a, 1), h;
  for (int i = 0; i < h1.size(); i++) h.push_back(h1[i]);
  for (int i = int(h2.size()) - 2; i > 0; i--) h.push_back(h2[i]);
  return h;
}
bool inseg_in(const point &px, const point &py, const point &p) {
  return is0((py - px).det(p - px)) && (px - p).dot(py - p) < eps;
}
struct solution {
  bool emp;
  point p, q;
  solution() { emp = 1; }
  void init(point P, point Q) {
    p = P;
    q = Q;
    emp = 0;
  }
  void intersect(point a, point b) {
    if (emp) return;
    if (a == b) {
      if (p == q) {
        if (a != p) emp = 1;
      } else {
        if (inseg_in(p, q, a))
          p = q = a;
        else
          emp = 1;
      }
    } else {
      bool tp = (b - a).det(p - a) > -eps;
      bool tq = (b - a).det(q - a) > -eps;
      if (p == q) {
        if (!tp) emp = 1;
      } else {
        if (parallel(a, b, p, q)) {
          if (!tp) emp = 1;
        } else {
          if (!tp && !tq)
            emp = 1;
          else if (!tp && tq)
            p = intersection(p, q, a, b);
          else if (tp && !tq)
            q = intersection(p, q, a, b);
        }
      }
    }
  }
  void limit(int L) {
    intersect(point(0, 0), point(L, 0));
    intersect(point(L, 0), point(L, L));
    intersect(point(L, L), point(0, L));
    intersect(point(0, L), point(0, 0));
  }
  void debug() {
    if (0)
      cout << "emp=" << emp << " p=" << p.x << "," << p.y << " q=" << q.x << ","
           << q.y << endl;
  }
};
const int maxn = 100111;
int n;
int L, H;
bool type[maxn];
pair<int, point> P[maxn];
solution getseg(point x) {
  point S = point(0, x.x / x.y * H);
  point T = point(L, L - (L - x.x) / x.y * H);
  solution ret;
  ret.init(S, T);
  ret.limit(L);
  return ret;
}
solution getnxt(solution a, solution b, double r) {
  vector<point> v;
  for (int i = -1; i <= 1; i += 2) {
    for (int j = -1; j <= 2; j += 2) {
      point dlt(i * r, j * r);
      v.push_back(a.p + dlt);
      v.push_back(a.q + dlt);
    }
  }
  sort(v.begin(), v.end());
  vector<int> h = construct_chull(v);
  assert(h.size() > 0);
  h.push_back(h[0]);
  for (int i = 0; i + 1 < h.size(); i++) b.intersect(v[h[i]], v[h[i + 1]]);
  b.limit(L);
  return b;
}
solution pp[maxn];
bool check(double v) {
  solution cur;
  cur.init(P[0].second, P[0].second);
  for (int i = 1; i <= n; i++) {
    int dlt = P[i].first - P[i - 1].first;
    if (pp[i].emp) return false;
    cur = getnxt(cur, pp[i], dlt * v);
    if (cur.emp) return false;
  }
  return true;
}
int main() {
  n = getnum(), L = getnum(), H = getnum();
  int Sx, Sy;
  Sx = getnum(), Sy = getnum();
  P[0] = make_pair(0, point(Sx, Sy));
  for (int i = 1; i <= n; i++) {
    int t, x, y;
    t = getnum(), x = getnum(), y = getnum();
    P[i] = make_pair(t, point(x, y));
    pp[i] = getseg(P[i].second);
  }
  double l = 0, r = 1001;
  for (int i = 0; i < 30; i++) {
    double mid = (l + r) / 2;
    if (check(mid))
      r = mid;
    else
      l = mid;
  }
  if (l > 1000.5)
    puts("-1");
  else
    cout << fixed << setprecision(6) << l << endl;
  return 0;
}