#include #include #include #include #include #include #include #include #include #include #include #include using namespace std; using ll = long long; int main() { int a, b, c, d, e, f; cin >> a >> b >> c >> d >> e >> f; printf("%.10f\n", sqrt(f - e + c * c / (4.0 * a) + d * d / (4.0 * b))); return 0; }