corn-destroyer
Source: hackerearth
Difficulty: UNKNOWN_DIFFICULTY

Murphy wants her brother Tom to leave their house as she need to do some serious work inside the house to save the earth!

But Tom is not ready to leave the house.

There is a infinitely large corn field in front of the house. Tom has also grown some mango trees in the corn field. Murphy knows if she destroys all the mango trees, Tom will leave the house for sure.

Murphy has a special powerful laser, which can destroy all the plants and trees up to infinite distance in the direction of laser ray.

This laser has few limitations-

Laser can be switched on only one time. Once it is switched off, it cannot be switched on again. 

Once switched on, it can remain in same state for any amount of time.

After turning it on, Murphy is not allowed to move from one place to another in the field.

She can rotate on her place to destroy the corns and trees.

Unfortunately, when Murphy rotates to destroy mango trees, laser also destroys all the corns in that sector.

Murphy also loves corns so she wants to save the maximum amount of corn in this action.

Her Ghost has already told her the coordinates of all mango trees in the corn field and also given her the coordinates in the field from where she has to perform action.

Now your task is to find the percentage of the destroyed corn field.

It is guaranteed that there will not be any mango tree where Murphy is standing.

Input

First line will contain an integer t - number of test cases

In each of the test case-

First line will have two space separated integers Xm and Ym - coordinates of Murphy's position.

Next line will have one integer N - Number of mango trees in the field.

Next N lines will have two space separated integers Xi and Yi each - coordinates of ith mango tree.

Output

Your output should be the percentage of corn which is destroyed which should contain exactly 6 digits after decimal point.

Constraints:

t ≤ 10

1 ≤ N ≤ 10^5

|Xi|, |Yi| ≤ 1000

|Xm|, |Ym| ≤ 1000

SAMPLE INPUT
2
1 1
3
4 2
2 4
4 4
1 1
4
3 1
4 2
2 4
-5 1

SAMPLE OUTPUT
14.758362
50.000000