Let's shoot down the balloon.#4277

Let's shoot down the balloon.

2 seconds
64 megabytes
Easy

Winnie the Pooh and Piglet are on another adventure to steal honey from the bees, and once again, they've found themselves in a tricky situation. Piglet needs to use his hunting rifle to pop the balloon that Winnie the Pooh has used to float up to the honey-filled hollow. The goal is to hit the balloon without the bullet touching Winnie the Pooh at all. Your task is to determine the optimal shooting position for Piglet.

In this scenario, Winnie the Pooh is represented as a sphere with a radius of . The center of this sphere is located at a height of H_p above the ground. Directly above Winnie, there is another sphere representing the balloon, with a radius of . The center of the balloon is positioned at a height of H_s above the ground. Both spheres are aligned vertically, sharing the same central axis. It is guaranteed that these spheres do not intersect, although they may touch.

Assume Piglet's rifle fires in a perfectly straight line. Calculate the minimum distance that Piglet must stand from the takeoff point (directly beneath the centers) to successfully hit the balloon, such that the bullet's trajectory grazes the balloon's surface and does not touch Winnie the Pooh at all.

Input

The input consists of a single line containing four positive integers: , H_p, , and H_s (1 \leq P, H_p, S, H_s \leq 10000).

Output

Output the minimum distance from the takeoff point from which Piglet can hit the balloon with the rifle, with a precision of at least decimal places.

Examples

Example 1

Loading
Loading