from decimal import * a,b,c,d,e,f = input().split() a = Decimal(a) b = Decimal(b) c = Decimal(c) d = Decimal(d) e = Decimal(e) f = Decimal(f) f -= e c /= a d /= a f /= a f += (c**Decimal('2'))/Decimal('4') f += (d**Decimal('2'))/Decimal('4') #print (a,f) print (abs(f)**Decimal('0.5'))