#include #include using namespace std; using mint = atcoder::modint1000000007; void fast_io() { ios::sync_with_stdio(false); std::cin.tie(nullptr); } int main() { fast_io(); int a, b, c, d, e, f; cin >> a >> b >> c >> d >> e >> f; double ans = (double)(4 * a * (f - e) + c * c + d * d) / (4 * a * a); ans = sqrt(ans); cout << setprecision(16) << fixed << ans << endl; }