G. [White] Can You find the Area ?
time limit per test
1 second
memory limit per test
256 megabytes
input
standard input
output
standard output

Laith was walking around the University of Jordan with Aziz, they were trying to have fun, so Aziz decided to give Laith a regular polygon with $$$N$$$ vertices (an $$$N$$$-gon) has $$$n$$$ equal sides and $$$N$$$ equal angles and give Laith a side length $$$S$$$.

After that, Aziz will ask Laith $$$Q$$$ questions, in each question Aziz will give Laith $$$3$$$ vertices of the $$$n$$$-gon, Laith needs to find the area of the resulted triangle when connecting the $$$3$$$ points.

Input

The first line contains one integer $$$T$$$ ($$$1 \le T \le 10^4)$$$ –denotes the number of test cases.

The first line of each test case contains three integers $$$N$$$, $$$S$$$, and $$$Q$$$ ($$$3 \le N \le 10^9$$$, $$$1 \le S \le 1000$$$, $$$1 \le Q \le 2 \cdot 10^5$$$) — denotes the number of vertices in the polygon, the side length of the polygon, and the number of queries, respectively.

Each of the next $$$Q$$$ lines contains three integers $$$u$$$, $$$v$$$, and $$$w$$$ ($$$1 \le u, v, w \le N$$$) — denotes the indices of the vertices chosen for the query.

It is guaranteed that $$$u, v$$$, and $$$w$$$ are distinct.

Output

For each query, output the area of the triangle formed by the vertices $$$u, v$$$, and $$$w$$$.

Your answer will be considered correct if its absolute or relative error does not exceed $$$10^{-9}$$$. Formally, let your answer be $$$a$$$, and the jury's answer be $$$b$$$. Your answer is accepted if and only if $$$\frac{\vert{}a - b\vert{}}{\max(1, \vert{}b\vert{})} \le 10^{-9}$$$.

Example
Input
2
3 1 1
1 2 3
6 5 2
1 3 5
1 2 4
Output
0.433012702
32.475952642
21.650635095