
There are exactly complex -th roots of unity. Denote these roots as \omega_0, \omega_1, , \omega_{n-1}, where
for k = 0, 1, \ldots, n-1.
Given a complex number , find the integer such that \omega_k = z.
The first line contains an integer (1 \le n \le 100).
The second line contains two real numbers and , each with nine digits after the decimal point. It is guaranteed that a + bi is one of the -th roots of unity.
Output the integer such that \omega_k = a + bi.
Example 1