Problem: There is a polyline going through points (0, 0) – (x, x) – (2x, 0) – (3x, x) – (4x, 0) – ... - (2kx, 0) – (2kx + x, x) – .... 

We know that the polyline passes through the point (a, b). Find minimum positive value x such that it is true or determine that there is no such x.

Input

Only one line containing two positive integers a and b (1 ≤ a, b ≤ 109).

Output

Output the only line containing the answer. Your answer will be considered correct if its relative or absolute error doesn't exceed 10 - 9. If there is no such x then output  - 1 as the answer.

Examples

Input

3 1


Output

1.000000000000


Input

1 3


Output

-1


Input

4 1


Output

1.250000000000

Note

You can see following graphs for sample 1 and sample 3. 

<image> <image>

Solution (in JAVA):

Solution:
import java.awt.Point;
import java.io.*;
import java.lang.Integer;
import java.lang.reflect.Array;
import java.math.BigInteger;
import java.util.*;
import java.util.ArrayDeque;

import static java.lang.Math.*;

public class Main {

    final boolean ONLINE_JUDGE = !new File("input.txt").exists();
    BufferedReader in;
    PrintWriter out;
    StringTokenizer tok = new StringTokenizer("");

    void init() throws FileNotFoundException {
        if (ONLINE_JUDGE) {
            in = new BufferedReader(new InputStreamReader(System.in));
            out = new PrintWriter(System.out);
        } else {
            in = new BufferedReader(new FileReader("input.txt"));
            out = new PrintWriter("output.txt");
        }
    }

    String readString() throws IOException {
        while (!tok.hasMoreTokens()) {
            tok = new StringTokenizer(in.readLine());
        }
        return tok.nextToken();
    }

    int readInt() throws IOException {
        return Integer.parseInt(readString());
    }

    long readLong() throws IOException {
        return Long.parseLong(readString());
    }

    double readDouble() throws IOException {
        return Double.parseDouble(readString());
    }

    public static void main(String[] args) {
        new Main().run();
        // Sworn to fight and die
    }

    public void run() {
        try {
            long t1 = System.currentTimeMillis();
            init();
            solve();
            out.close();
            long t2 = System.currentTimeMillis();
            System.err.println("Time = " + (t2 - t1));
        } catch (Exception e) {
            e.printStackTrace(System.err);
            System.exit(-1);
        }
    }

    class LOL implements Comparable<LOL> {
        int x;
        int y;


        public LOL(int x, int y) {
            this.x = x;
            this.y = y;
        }

        @Override
        public int compareTo(LOL o) {

            if (o.x != x)
                return (int) (o.x - x); // ---->
            return (int) (o.y - y); // <----
        }

    }

    int ans = 0;

    int[] readIntArray (int n) throws IOException {
        int[] a = new int[n];

        for (int i = 0; i < n; i++) a[i] = readInt();

        return a;
    }


    public void solve() throws IOException {
        double a = readDouble();
        double b = readDouble();

        if (a < b) {
            out.print("-1"); return;
        }
        if (a == b) {
            out.print(  a); return;
        }

        double x1 = a + b;
        double x2 = a - b;

        int k1 = (int)(x1 / b) ;
        int k2 = (int)(x2 / b);
        double ans1 = 0;
        double ans2 = 0;
        if (k2 % 2 == 0) ans2 = x2 /k2;
        else if (k2 == 1) ans2 = Double.MAX_VALUE;
        else ans2 = x2 / (k2 - 1);

        if (k1 % 2 == 0) ans1 = x1 /k1;
        else ans1 = x1 / (k1 - 1);


        out.print(min(ans1,ans2));

        }
}