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.
import java.io.*;
import java.util.Arrays;
import java.util.StringTokenizer;

public class E_as {
    FastScanner in;
    PrintWriter out;

    double vmul(double x1, double y1, double x2, double y2) {
        return x1 * y2 - x2 * y1;
    }

    double smul(double x1, double y1, double x2, double y2) {
        return x1 * x2 + y1 * y2;
    }

    double det2(double a, double b, double c, double d) {
        return a * d - b * c;
    }

    double EPS = 1e-6;

    double intersect(Semi a, Semi b) {
        double a11 = a.dx;
        double a12 = -b.dx;
        double a21 = a.dy;
        double a22 = -b.dy;
        double b1 = b.x - a.x;
        double b2 = b.y - a.y;

        double d = det2(a11, a12, a21, a22);
        if (Math.abs(d) < EPS) {
            return Double.NaN;
        }
        return det2(b1, a12, b2, a22) / d;
    }

    class Semi {
        double x;
        double y;
        double dx;
        double dy;

        Semi(double x1, double y1, double x2, double y2) {
            this.x = x1;
            this.y = y1;
            dx = x2 - x1;
            dy = y2 - y1;
            double d = Math.sqrt(dx * dx + dy * dy);
            dx = dx / d;
            dy = dy / d;
        }
    }

    double area(Semi[] a) {
        int n = a.length;
        double res = 0;
        for (int i = 0; i < n; i++) {
            double from = Double.NEGATIVE_INFINITY;
            double to = Double.POSITIVE_INFINITY;
            for (int j = 0; j < n; j++) {
                if (i != j) {
                    double pos = intersect(a[i], a[j]);
                    if (Double.isNaN(pos)) {
                        if (vmul(a[j].dx, a[j].dy, a[i].x - a[j].x, a[i].y - a[j].y) < -EPS) {
                            return 0;
                        }
                    } else if (vmul(a[i].dx, a[i].dy, a[j].dx, a[j].dy) > 0) {
                        to = Math.min(to, pos);
                    } else {
                        from = Math.max(from, pos);
                    }
                }
            }
            if (from < to) {
                res += vmul(a[i].x + a[i].dx * from, a[i].y + a[i].dy * from, a[i].x + a[i].dx * to, a[i].y + a[i].dy * to);
            }
        }
        return res;
    }

    public void solve() throws IOException {
        int n = in.nextInt();
        int h = in.nextInt();
        int f = in.nextInt();
        int[] l = new int[n];
        int[] r = new int[n];
        double ans = 0;
        Semi[][] s = new Semi[n][4];

        for (int i = 0; i < n; i++) {
            l[i] = in.nextInt();
            r[i] = in.nextInt();

            double th1 = f - h;
            double th2 = f + h;
            double ts1 = r[i] - l[i];
            double ts2 = (r[i] - l[i]) * th2 / th1;
            double area = (ts2 * th2 - ts1 * th1);
            ans += area;

            s[i][0] = new Semi(0, f, l[i], h);
            s[i][1] = new Semi(r[i], h, 0, f);
            s[i][2] = new Semi(l[i], -h, 0, -f);
            s[i][3] = new Semi(0, -f, r[i], -h);
        }

        Semi top = new Semi(1, h, 0, h);
        Semi bot = new Semi(0, -h, 1, -h);

        Semi[] ss = new Semi[6];
        ss[0] = top;
        ss[1] = bot;
        for (int i = 0; i < n; i++) {
            for (int j = 0; j < n; j++) {
                ss[2] = s[i][0];
                ss[3] = s[i][1];
                ss[4] = s[j][2];
                ss[5] = s[j][3];
                double area = area(ss) / 2.0;
                ans -= area;
            }
        }
        out.println(ans);
    }

    public void run() {
        try {
            in = new FastScanner(System.in);
            out = new PrintWriter(System.out);

            solve();

            out.close();
        } catch (IOException e) {
            e.printStackTrace();
        }
    }

    class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        FastScanner(InputStream f) {
            br = new BufferedReader(new InputStreamReader(f));
        }

        String next() {
            while (st == null || !st.hasMoreTokens()) {
                try {
                    st = new StringTokenizer(br.readLine());
                } catch (IOException e) {
                    e.printStackTrace();
                }
            }
            return st.nextToken();
        }

        int nextInt() {
            return Integer.parseInt(next());
        }
    }

    public static void main(String[] arg) {
        new E_as().run();
    }
}