import java.util.*;
import java.math.*;
import java.text.DecimalFormat;
public class Main {
public static void main(String args[])
{
Scanner cin=new Scanner(System.in);
double x1,y1,x2,y2;
DecimalFormat df = new DecimalFormat("0.00");
while(cin.hasNext())
{
x1=cin.nextDouble();
y1=cin.nextDouble();
x2=cin.nextDouble();
y2=cin.nextDouble();
double temp;
temp=Math.sqrt(((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2)));
System.out.println(df.format(temp));
}
}
}
时间: 2024-10-22 12:29:19