杭电2001

#include <iostream>

#include <iomanip>

#include <cmath>

using namespace std;

int main()

{

    double x1,y1,x2,y2;

    double result;

    while (cin>>x1>>y1>>x2>>y2)

    {

        result = sqrt((x1-x2)*(x1-x2)+(y1-y2)*(y1-y2));

        cout << setprecision(2) << setiosflags(ios::fixed) << result << endl;

    }

    return 0;

}

 

你可能感兴趣的:(杭电)