Problem: The determinant of a matrix 2 × 2 is defined as follows:

<image>

A matrix is called degenerate if its determinant is equal to zero. 

The norm ||A|| of a matrix A is defined as a maximum of absolute values of its elements.

You are given a matrix <image>. Consider any degenerate matrix B such that norm ||A - B|| is minimum possible. Determine ||A - B||.

Input

The first line contains two integers a and b (|a|, |b| ≤ 109), the elements of the first row of matrix A. 

The second line contains two integers c and d (|c|, |d| ≤ 109) the elements of the second row of matrix A.

Output

Output a single real number, the minimum possible value of ||A - B||. Your answer is considered to be correct if its absolute or relative error does not exceed 10 - 9.

Examples

Input

1 2
3 4


Output

0.2000000000


Input

1 0
0 1


Output

0.5000000000

Note

In the first sample matrix B is <image>

In the second sample matrix B is <image>

Solution (in JAVA):

Solution:
import java.util.*;
import java.math.*;
import static java.lang.System.*;

public class CF549H{
	public static BigDecimal a, b, c, d;
	
	public static boolean check(BigDecimal x){
		BigDecimal ua = a.subtract(x).max(a.add(x)), la = a.subtract(x).min(a.add(x));
		BigDecimal ub = b.subtract(x).max(b.add(x)), lb = b.subtract(x).min(b.add(x));
		BigDecimal uc = c.subtract(x).max(c.add(x)), lc = c.subtract(x).min(c.add(x));
		BigDecimal ud = d.subtract(x).max(d.add(x)), ld = d.subtract(x).min(d.add(x));
		BigDecimal u1 = ua.multiply(ud).max(ua.multiply(ld)).max(la.multiply(ud)).max(la.multiply(ld));
		BigDecimal l1 = ua.multiply(ud).min(ua.multiply(ld)).min(la.multiply(ud)).min(la.multiply(ld));
		BigDecimal u2 = ub.multiply(uc).max(ub.multiply(lc)).max(lb.multiply(uc)).max(lb.multiply(lc));
		BigDecimal l2 = ub.multiply(uc).min(ub.multiply(lc)).min(lb.multiply(uc)).min(lb.multiply(lc));
		// out.printf("	%.10f %.10f %.10f %.10f\n", ua.doubleValue(), la.doubleValue(), ud.doubleValue(), ld.doubleValue());
		// out.printf("	%.10f %.10f %.10f %.10f\n", ub.doubleValue(), lb.doubleValue(), uc.doubleValue(), lc.doubleValue());
		// out.printf("	%.10f %.10f %.10f %.10f\n", u1.doubleValue(), l1.doubleValue(), u2.doubleValue(), l2.doubleValue());
		if(u1.compareTo(l2) < 0 || l1.compareTo(u2) > 0) return false;
		return true;
	}
	
	public static void main(String[] args){
		Scanner sc = new Scanner(in);
		
		a = BigDecimal.valueOf(sc.nextDouble());
		b = BigDecimal.valueOf(sc.nextDouble());
		c = BigDecimal.valueOf(sc.nextDouble());
		d = BigDecimal.valueOf(sc.nextDouble());
		BigDecimal eps = BigDecimal.valueOf(1e-10);
		
		BigDecimal L = BigDecimal.ZERO;
		BigDecimal R = a.abs().max(b.abs()).max(c.abs()).max(d.abs());
		while(R.subtract(L).compareTo(eps) > 0){
			BigDecimal M = L.add(R).divide(BigDecimal.valueOf(2));
			// out.printf("%.10f %.10f %.10f\n", M.doubleValue(), L.doubleValue(), R.doubleValue());
			if(check(M)){
				R = M;
			}else{
				L = M;
			}
		}

		out.printf("%.10f\n", L.doubleValue());
	}
}