import math def main(): a,b,c,d,e,f = map(int,input().split()) child = math.sqrt(4*(a*f-a*e) + c*c + d*d) mother = 2*a ans = child/mother return ans print(main())