import java.util.Scanner; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(System.in); int a = sc.nextInt(); int b = sc.nextInt(); double c = sc.nextInt(); double d = sc.nextInt(); double e = sc.nextInt(); double f = sc.nextInt(); sc.close(); if (a != b) { System.out.println(0); return; } c /= a; d /= a; f = (f - e) / a; c = c * c / 4; d = d * d / 4; f = f + c + d; System.out.println(Math.sqrt(f)); } }