beecrowd | 2088

Dengue

By Gabriel Duarte, UNIFESO BR Brazil

Timelimit: 2

After John found he was with dengue, he became very angry. As in recent days he does not left home, the mosquito that bit him could only be some dengue focus near his home. Then when he had an idea.

When he is a little better, John will kill all the mosquitoes spots that are close by from your home. To accomplish this task he got a map, which can be seen as a cartesian plane, where your home and each have a distinct focus coordinate. As dengue is a disease that makes the body well debilitated, John needs your help in this task.

John would like to know the minimum total distance he will spend to get out of your home, visit all dengue outbreaks exactly once and return home. Can you help John in his mission?

Input

The input contains several test cases. The first line of each test case will an integer N (1 ≤ N ≤ 15),representing the amount of mosquito focuses on the map. Follows a line containing two integers X and Y (-100 ≤ X, Y ≤ 100), representing the coordinate of John's home. Then have N rows, each containing two integers X and Y (-100 ≤ X, Y ≤ 100), representing the coordinate of a focus dengue. The entrance ends when N = 0 and is not to be processed.

Output

For each test case print the minimum distance that John will travel to two decimal places.

Input Sample Output Sample

4
0 0
1 2
2 3
2 2
3 3
0

8.89