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 CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
long long bigmod(long long p, long long e, long long M) {
  long long ret = 1;
  for (; e > 0; e >>= 1) {
    if (e & 1) ret = (ret * p) % M;
    p = (p * p) % M;
  }
  return ret;
}
long long extended(long long a, long long b, long long &x, long long &y) {
  a = abs(a);
  b = abs(b);
  long long g, x1, y1;
  if (!b) {
    x = 1;
    y = 0;
    g = a;
    return g;
  }
  g = extended(b, a % b, x1, y1);
  x = y1;
  y = x1 - (a / b) * y1;
  return g;
}
long long modinverse(long long a, long long M) { return bigmod(a, M - 2, M); }
long long bpow(long long p, long long e) {
  long long ret = 1;
  for (; e > 0; e >>= 1) {
    if (e & 1) ret = (ret * p);
    p = (p * p);
  }
  return ret;
}
int toInt(string s) {
  int sm;
  stringstream ss(s);
  ss >> sm;
  return sm;
}
int toLlint(string s) {
  long long int sm;
  stringstream ss(s);
  ss >> sm;
  return sm;
}
string convertInt(long long number) {
  if (number == 0) return "0";
  string temp = "";
  string returnvalue = "";
  while (number > 0) {
    temp += number % 10 + 48;
    number /= 10;
  }
  for (int i = 0; i < temp.length(); i++)
    returnvalue += temp[temp.length() - i - 1];
  return returnvalue;
}
long long ncr[1001][1001];
void NCR() {
  for (int i = 1; i <= 1000; i++) {
    ncr[i][i] = 1;
    ncr[i][0] = 1;
    for (int r = 1; r < i; r++) {
      ncr[i][r] = (ncr[i - 1][r] + ncr[i - 1][r - 1]) % 1000000007;
    }
  }
}
double a, b;
double solve(double x) {
  double q, ht;
  double res = 1000000000009;
  int lo, hi, mid;
  lo = 0, hi = 1000000000;
  while (lo <= hi) {
    mid = (lo + hi) / 2;
    q = (x * 1.0) / mid;
    ht = q / 2.0;
    if (ht >= b)
      lo = mid + 1, res = ht;
    else
      hi = mid - 1;
  }
  return res;
}
int main() {
  cin >> a >> b;
  if (a < b) {
    cout << "-1" << endl;
    return 0;
  }
  cout << fixed << setprecision(11) << min(solve(a - b), solve(a + b)) << endl;
  return 0;
}