In the plan area is depicted N cottages, which have known coordinates X, Y (i = 1 .. N). What is the minimum length should be the total length of water pipes that connects all the houses N of the town, directly or through several intermediate houses?
The first line number N - the number of houses. The next N lines coordinates cottages X, Y (i = 1 .. N). All input values are natural numbers not greater than 100.
Single number - the total length of water pipes, rounded to integers.