Problem: 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.

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int a, b, c, d, e, f, g, h, i, j, k;
double L[100005], R[100005];
struct Point {
  double x, y;
  Point() {}
  Point(double x, double y) : x(x), y(y) {}
  friend double operator*(const Point &x, const Point &y) {
    return x.x * y.y - x.y * y.x;
  }
  friend bool operator<(const Point &x, const Point &y) {
    return atan2(x.x, x.y) < atan2(y.x, y.y);
  }
  friend struct Point operator-(const Point &x, const Point &y) {
    struct Point kk;
    kk.x = x.x - y.x;
    kk.y = x.y - y.y;
    return kk;
  }
};
struct Point p[100005];
struct Point ch, ch1, ch2;
int ok;
struct node {
  struct Point q, z;
  struct Point F;
  friend bool operator<(const node &x, const node &y) { return x.F < y.F; }
};
struct node Line[100005];
struct node que[100005];
int l, r;
double u, v, w, o, q;
double an;
void Join(int x, int y) {
  if (y > 0) {
    Line[++k].q = Point(L[x], u);
    Line[k].z = Point(0, v);
    Line[++k].q = Point(0, v);
    Line[k].z = Point(R[x], u);
  } else {
    Line[++k].q = Point(0, -v);
    Line[k].z = Point(L[x], -u);
    Line[++k].q = Point(R[x], -u);
    Line[k].z = Point(0, -v);
  }
}
void Make_F(int x) {
  Line[x].F.x = Line[x].z.x - Line[x].q.x;
  Line[x].F.y = Line[x].z.y - Line[x].q.y;
}
int Onleft(struct Point x, struct node y) {
  int ii, jj, kk;
  ch1 = y.F;
  ch2.x = x.x - y.q.x;
  ch2.y = x.y - y.q.y;
  return ch1 * ch2 > 0;
}
struct Point Jiao(struct node x, struct node y) {
  int ii, kk;
  double jj;
  struct Point ch;
  ch = x.q - y.q;
  jj = y.F * ch;
  jj /= x.F * y.F;
  ch1.x = jj * x.F.x + x.q.x;
  ch1.y = jj * x.F.y + x.q.y;
  return ch1;
}
void Half_Jiao() {
  int ii, jj, kk;
  for (ii = 1; ii <= k; ii++) Make_F(ii);
  sort(Line + 1, Line + k + 1);
  l = 1;
  r = 0;
  que[++r] = Line[1];
  for (ii = 2; ii <= k; ii++) {
    while (l < r && Onleft(p[r], Line[ii])) r--;
    while (l < r && Onleft(p[l + 1], Line[ii])) l++;
    que[++r] = Line[ii];
    if (fabs(Line[ii].F * que[r - 1].F) < 1e-6) {
      r--;
      if (Onleft(que[r - 1].z, Line[ii])) que[r] = Line[ii];
    }
    if (l < r) p[r] = Jiao(que[r], que[r - 1]);
  }
  while (l < r && Onleft(p[r], que[l])) r--;
  if (r - l < 1) ok = 0;
  p[l] = Jiao(que[l], que[r]);
}
double MianJi() {
  int ii;
  double jj, kk;
  kk = 0;
  for (ii = l + 1; ii <= r - 1; ii++) {
    ch1 = p[ii] - p[l];
    ch2 = p[ii + 1] - p[l];
    jj = fabs(ch1 * ch2);
    jj /= 2;
    kk += jj;
  }
  return kk;
}
int main() {
  scanf("%d%lf%lf", &a, &u, &v);
  Line[1].q = Point(-1, u);
  Line[1].z = Point(1, u);
  Line[2].q = Point(1, -u);
  Line[2].z = Point(-1, -u);
  for (i = 1; i <= a; i++) scanf("%lf%lf", &L[i], &R[i]);
  for (i = 1; i <= a; i++)
    an += (R[i] - L[i]) * (v - u) * ((v + u) / (v - u)) * ((v + u) / (v - u)) -
          (R[i] - L[i]) * (v - u);
  for (i = 1; i <= a; i++)
    for (j = 1; j <= a; j++) {
      k = 2;
      ok = 1;
      Line[1].q = Point(-1, u);
      Line[1].z = Point(1, u);
      Line[2].q = Point(1, -u);
      Line[2].z = Point(-1, -u);
      Join(i, 1);
      Join(j, -1);
      Half_Jiao();
      if (ok) {
        o = MianJi();
        an -= o;
      }
    }
  printf("%lf\n", an);
  return 0;
}