from math import sqrt a, b, c, d, e, f = map(int, input().split()) print(sqrt(f-e+sqrt(c/2/a)+sqrt(d/2/b)))