SP9641 FBRIDGES - Factory of Bridges

Description

_Original statement in spanish at _ In the Central Area of Macedonia there is a river following the East-West direction. The region's inhabitants want to build a bridge that crosses the river in the North-South direction, a task for which they have contracted the cheapest bridge factory they know, the Short Bridge Construction Company. As shown by its name, this construction company specializes in building the shortest possible bridges for each river. The first thing that the company does is to model the river's shores (Northern and Southern). Each of these is considered as being formed by semicircles of varying radii, alternatively oriented to one side or the other, with all their centers collinear. The two lines that are defined by the centers of the semicircles of each shore have the East-West direction, and are separated by a distance **A** one from the other. The value **A** is called the width of the river. Note that both shores are aligned, that is, the Northern shore neither begins nor ends further to the West or to the East than the Southern shore. In the following figure you can see the model of a certain river. In the Northern shore the semicircle furthest to the West is oriented to the North, whereas in the Southern shore the semicircle furthest to the West is oriented to the South. In each shore the orientations of the following semicircles alternate. The shortest possible bridge in the North-South direction is the one shown. ![](https://cdn.luogu.com.cn/upload/vjudge_pic/SP9641/3b47e5936b84d09b1d3837c990493980ff1fea42.png) Your task is to help the construction company finding the length of the shortest possible bridge connecting both shores of the river in the North-South direction.

Input Format

The input contains several test cases. Each test case is described by three lines. The first line contains an integer number **A**, denoting the width of the river in meters (3

Output Format

For each test case, print a single line containing a rational number representing the length in meters of the shortest bridge that connects both shores of the given river in the North-South direction. Round the result to the nearest rational number with 2 decimal digits. In case of ties, round up. Note that you should always print 2 digits after the dot, even if this means ending with a zero.