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>
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Set;


public class test {
	
	public static void main(String[] args) {
		polyline();
	}

	static double getX(int target, int b, int minLoop) {
//		System.out.println(target+ " " + b + " " + minLoop);
		if(target == 0)  return b;
		if(b == 0 || (double)target/b < (double)minLoop)  return Double.MAX_VALUE; 
		
		int loop = target / b;
		if(loop%2 == 0)  
			return (double)target/(double)loop;
		
		return (double)target/(double)(loop-1);             		
	}
	
	static void polyline() {
		try{
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
				
			String input;
			if((input=br.readLine()) == null)  
				System.err.println("Bad Input");
			
			String[] ss = input.split(" ");
			if(ss.length != 2)
				System.err.println("Bad Input");
			
			int a = Integer.parseInt(ss[0]), b = Integer.parseInt(ss[1]);
			
			//int negH = a + b, posH = a - b;
			double l = getX(a-b, b, 0);
			double r = getX(a+b, b, 2);
			//System.out.println(l+ " " + r);
			double x = Math.min(l, r);
			
			if(x == Double.MAX_VALUE)  System.out.println(-1);
			else                       System.out.println(x);
		} catch (IOException io){
			io.printStackTrace();
		}		
	}
	
	/* --------------------------------------------------------- */
	static class sComb implements Comparable<sComb> {
		public int S;
		public int A;
		public int B;
		public sComb(int s, int a, int b) {
			S = s;
			A = a;
			B = b;
		}
		
		@Override
		public int compareTo(sComb arg0) {
			return -Integer.compare(this.S, arg0.S);
		}
	}
	
	static void findTeamMember() {
		try{
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
				
			String input;
			if((input=br.readLine()) == null)  
				System.err.println("Bad Input");
			
			int numOfMember = Integer.parseInt(input)*2;
			List<sComb> slist = new ArrayList<>();
			
			int A = 1;
			while(A++ < numOfMember) {
				if((input=br.readLine()) == null)  
					System.err.println("Bad Input");
				
				String[] ss = input.split(" ");
				for(int B=1; B<=ss.length; B++) {
					slist.add(new sComb(Integer.parseInt(ss[B-1]), A, B));
				}
			}
			
			Collections.sort(slist);
			
			int[] member  = new int[numOfMember+1];
			Set<Integer> set = new HashSet<>();
			
			for(int i=0; i<slist.size(); i++) {
				sComb t = slist.get(i);
				if(set.contains(t.A) || set.contains(t.B))  
					continue;
				
				member[t.A] = t.B;
				member[t.B] = t.A;
				set.add(t.A);
				set.add(t.B);
				if(set.size() == numOfMember)
					break;
			}

			for(int i=1; i<=numOfMember; i++)
				System.out.print(member[i]+" ");
			System.out.println();
					
		} catch (IOException io){
			io.printStackTrace();
		}	
	}
	
	/* --------------------------------------------------------- */
	
	static void minBacteria() {
		try{
			BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
				
			String input;
			if((input=br.readLine()) == null)  
				System.err.println("Bad Input");
			
			{
				int in = Integer.parseInt(input), out = 0;
				while(in >= 1) {
					int temp = 1;
					while(in/2 >= temp)  temp *= 2;
					in -= temp;
					out++;
				}
				System.out.println(out);
			}
		} catch (IOException io){
			io.printStackTrace();
		}		
	}
}
