PROGRAMMING:Function template
Data spacing problem (function template)
Class point has two data members: X and y, representing X and Y coordinates respectively, and has several constructors and a member function overloaded - (minus sign, calculating the distance between two points).
Require the design of a function template
```
template < class T >
double dist(T a, T b)
```
For int, float, point or other types of data, return the spacing.
###Input format:
Each line has an operation. The first number of each line is the element type. 1 is the integer element, 2 is the floating-point element, and 3 is the point type. If it is an integer element, then enter two integer data. If it is a floating-point element, then enter two floating-point data. If it is a point element, enter two point data (x1 Y1 x2 Y2). When you enter 0, it marks the end of the input.
###Output format:
For each input, output a spacing value per line.
###Input example:
```in
1 2 5
3 2 4 5 9
2 2.2 9.9
0
```
###Output example:
```out
three
five point eight three zero nine five
seven point seven
```
answer:If there is no answer, please comment
Class point has two data members: X and y, representing X and Y coordinates respectively, and has several constructors and a member function overloaded - (minus sign, calculating the distance between two points).
Require the design of a function template
```
template < class T >
double dist(T a, T b)
```
For int, float, point or other types of data, return the spacing.
###Input format:
Each line has an operation. The first number of each line is the element type. 1 is the integer element, 2 is the floating-point element, and 3 is the point type. If it is an integer element, then enter two integer data. If it is a floating-point element, then enter two floating-point data. If it is a point element, enter two point data (x1 Y1 x2 Y2). When you enter 0, it marks the end of the input.
###Output format:
For each input, output a spacing value per line.
###Input example:
```in
1 2 5
3 2 4 5 9
2 2.2 9.9
0
```
###Output example:
```out
three
five point eight three zero nine five
seven point seven
```
answer:If there is no answer, please comment