2021-11-26 02:15 AKST



2021-11-26 04:15 AKST
The end is near!
Contest is over.
Not yet started.
Contest is starting in -19140 days 23:32:45

Time elapsed


Time remaining


Problem B

A factory is making ornaments for the upcoming holidays. Ornaments consist of a 2D glass sphere (i.e., a circle) that is designed to hang off a hook or nail using a string that tightly wraps around the ornament, as shown in the figure to the right.

Your task is to write a program that calculates the length of the string, given the radius $r$ of the circle, the distance $h$ from the knot to the center of the circle, and some multiplier to account for the excess needed to tie the knot.


The input will contain multiple test cases, up to $200$. Each test case contains on a single line three integers $r$ ($1 \le r \le 10,000$), $h$ ($r \le h \le 10,000$), and $s$ ($0 \le s \le 100$). $s$ denotes the necessary excess string in %. The percentage is relative to what would be needed without accounting for the knot, so if $s = 25$, you should increment the necessary length by $1/4$.

The input will be terminated by a line containing $3$ zeros.


For each test case, output the length of the needed string, rounded to two decimals.

Sample Input 1 Sample Output 1
1 3 10
2 5 8
10 11 0
0 0 0