import java.util.Scanner;
class point
{
double x, y;
point(double x, double y)
{
this.x = x;
this.y = y;
}
public double getX()
{
return x;
}
public double getY()
{
return y;
}
}
public class Test02
{
public static void main(String args[])
{
double x1, y1, x2, y2, x3, y3;
Scanner input = new Scanner(System.in);
System.out.println("请分别输入A,B,C三点坐标,分别用x1,y1,x2,y2,x3,y3表示");
System.out.println("请输入x1的坐标:");
x1 = input.nextDouble();
System.out.println("请输入y1的坐标:");
y1 = input.nextDouble();
System.out.println("请输入x2的坐标:");
x2 = input.nextDouble();
System.out.println("请输入y2的坐标:");
y2 = input.nextDouble();
System.out.println("请输入x3的坐标:");
x3 = input.nextDouble();
System.out.println("请输入y3的坐标:");
y3 = input.nextDouble();
point d = new point(x1, y1);
point d1 = new point(x2, y2);
point d2 = new point(x3, y3);
System.out.println("A点到B点的距离为:" + distance(d, d1