lcg007


私信TA

用户名:qq1102765728

访问量:17710

签 名:

Null

等  级
排  名 479
经  验 4520
参赛次数 1
文章发表 34
年  龄 0
在职情况 在职
学  校 同济大学
专  业

  自我简介:

TA的其他文章


解题思路:

注意事项:

参考代码:

#include<iostream>

#include<iomanip>

#include<math.h>

using namespace std;


int main()

{

double x1,y1,x2,y2,s;

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

{

s = (x1 - x2)*(x1 - x2) + (y1 - y2)*(y1 - y2);

cout <<setprecision(2)<<fixed<<sqrt(s)<<endl;

}

return 0;

}


 

0.0分

0 人评分

看不懂代码?想转换其他语言的代码? 或者想问其他问题? 试试问问AI编程助手,随时响应你的问题:

编程语言转换

万能编程问答

代码解释器

  评论区