Consider a house plan. 

Let the house be represented by an infinite horizontal strip defined by the inequality  - h ≤ y ≤ h. Strictly outside the house there are two light sources at the points (0, f) and (0, - f). Windows are located in the walls, the windows are represented by segments on the lines y = h and y = - h. Also, the windows are arranged symmetrically about the line y = 0.

Your task is to find the area of the floor at the home, which will be lighted by the sources of light. 

<image>

Input

The first line of the input file contains three integers n, h and f (1 ≤ n ≤ 500, 1 ≤ h ≤ 10, h < f ≤ 1000). Next, n lines contain two integers each li, ri ( - 5000 ≤ li < ri ≤ 5000), each entry indicates two segments. Endpoints of the first segment are (li, h)-(ri, h), and endpoints of the second segment are (li, - h)-(ri, - h). These segments describe location of windows. Numbers in the lines are space-separated. It is guaranteed that no two distinct segments have common points. 

Output

Print the single real number — the area of the illuminated part of the floor with an absolute or relative error of no more than 10 - 4.

Examples

Input

1 1 2
-1 1


Output

10.0000000000


Input

2 2 4
-1 0
1 2


Output

23.3333333333

Note

The second sample test is shown on the figure. Green area is the desired area of the illuminated part of the floor. Violet segments indicate windows.
#include <bits/stdc++.h>
struct point {
  long double x, y;
};
point operator+(point a, point b) {
  point c;
  c.x = a.x + b.x, c.y = a.y + b.y;
  return c;
}
point operator-(point a, point b) {
  point c;
  c.x = a.x - b.x, c.y = a.y - b.y;
  return c;
}
point operator*(point a, long double b) {
  point c;
  c.x = a.x * b, c.y = a.y * b;
  return c;
}
long double operator*(point a, point b) { return a.x * b.x + a.y * b.y; }
long double operator%(point a, point b) { return a.x * b.y - a.y * b.x; }
bool operator==(point a, point b) {
  return fabs(a.x - b.x) < 1e-8 && fabs(a.y - b.y) < 1e-8;
}
int intersect(point p1, point p2, point q1, point q2, point* res = NULL) {
  long double t = (p2 - p1) % (q2 - q1);
  if (fabs(t) < 1e-8)
    if (fabs((q1 - p1) % (p2 - p1)) < 1e-8)
      if ((q1 - p1) * (q1 - p2) < -1e-8 || (q2 - p1) * (q2 - p2) < -1e-8 ||
          (p1 - q1) * (p1 - q2) < -1e-8 || (p2 - q1) * (p2 - q2) < -1e-8)
        return 2;
      else if (p1 == q1 || p1 == q2) {
        if (res) *res = p1;
        return 1;
      } else if (p2 == q1 || p2 == q2) {
        if (res) *res = p2;
        return 1;
      } else
        return 0;
    else
      return 0;
  else {
    long double t = ((q2 - p2) % (q1 - q2)) / ((p1 - p2) % (q1 - q2));
    if (t < -1e-8 || t > 1 + 1e-8) return 0;
    t = ((p2 - q2) % (p1 - p2)) / ((q1 - q2) % (p1 - p2));
    if (t < -1e-8 || t > 1 + 1e-8) return 0;
    if (res) *res = q2 + (q1 - q2) * t;
    return 1;
  }
}
int n;
double h, f, l[500], r[500], ans;
point tmp[8];
int main() {
  scanf("%d%lf%lf", &n, &h, &f);
  for (int i = 0; i < n; i++) {
    scanf("%lf%lf", &l[i], &r[i]);
    ans += (r[i] - l[i]) + (r[i] - l[i]) * (f + h) / (f - h);
  }
  ans *= 2 * h;
  for (int i = 0; i < n; i++)
    for (int j = 0; j < n; j++) {
      double x1 = l[i], x2 = r[i], x3 = l[j] * (f + h) / (f - h),
             x4 = r[j] * (f + h) / (f - h);
      double x5 = l[j], x6 = r[j], x7 = l[i] * (f + h) / (f - h),
             x8 = r[i] * (f + h) / (f - h);
      point p1;
      p1.x = x1, p1.y = h;
      point p2;
      p2.x = x2, p2.y = h;
      point p3;
      p3.x = x3, p3.y = h;
      point p4;
      p4.x = x4, p4.y = h;
      point p5;
      p5.x = x5, p5.y = -h;
      point p6;
      p6.x = x6, p6.y = -h;
      point p7;
      p7.x = x7, p7.y = -h;
      point p8;
      p8.x = x8, p8.y = -h;
      point c;
      int l = 0;
      if (x1 <= x4 + 1e-8 && x1 >= x3 - 1e-8) c.x = x1, c.y = h, tmp[l++] = c;
      if (x2 <= x4 + 1e-8 && x2 >= x3 - 1e-8) c.x = x2, c.y = h, tmp[l++] = c;
      if (x3 <= x2 + 1e-8 && x3 >= x1 - 1e-8) c.x = x3, c.y = h, tmp[l++] = c;
      if (x4 <= x2 + 1e-8 && x4 >= x1 - 1e-8) c.x = x4, c.y = h, tmp[l++] = c;
      if (x5 <= x8 + 1e-8 && x5 >= x7 - 1e-8) c.x = x5, c.y = -h, tmp[l++] = c;
      if (x6 <= x8 + 1e-8 && x6 >= x7 - 1e-8) c.x = x6, c.y = -h, tmp[l++] = c;
      if (x7 <= x6 + 1e-8 && x7 >= x5 - 1e-8) c.x = x7, c.y = -h, tmp[l++] = c;
      if (x8 <= x6 + 1e-8 && x8 >= x5 - 1e-8) c.x = x8, c.y = -h, tmp[l++] = c;
      if (intersect(p5, p3, p1, p7, &c) == 1) tmp[l++] = c;
      if (intersect(p5, p3, p2, p8, &c) == 1) tmp[l++] = c;
      if (intersect(p6, p4, p1, p7, &c) == 1) tmp[l++] = c;
      if (intersect(p6, p4, p2, p8, &c) == 1) tmp[l++] = c;
      for (int i = 1; i < l; i++)
        if (tmp[i].x < tmp[0].x) c = tmp[i], tmp[i] = tmp[0], tmp[0] = c;
      for (int i = 1; i < l; i++)
        for (int j = i + 1; j < l; j++)
          if ((tmp[j] - tmp[0]) % (tmp[i] - tmp[0]) > 1e-8 ||
              fabs((tmp[j] - tmp[0]) % (tmp[i] - tmp[0])) < 1e-8 &&
                  (tmp[j] - tmp[0]) * (tmp[j] - tmp[0]) <
                      (tmp[i] - tmp[0]) * (tmp[i] - tmp[0])) {
            c = tmp[j];
            tmp[j] = tmp[i];
            tmp[i] = c;
          }
      double t = 0;
      for (int i = 0; i < l; i++) t += tmp[i] % tmp[(i + 1) % l];
      ans -= t / 2;
    }
  printf("%lf\n", ans);
  return 0;
}
