杭电2001
2014-05-12 18:00
176 查看
#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; }
相关文章推荐
- 基于'sessionStorage'与'userData'的类session存储
- echsop设置伪静态
- vc操作注册表
- Http 通过Get获取数据
- linux编程-进程简介
- C++ 详细解说 STL 排序(Sort)
- linux下mysql自动备份脚本代码
- SVN强制在提交时要求添加注释说明(windows平台)
- ReSharper8.1.23.546注册机
- android代码优化
- PHP2014-5-12的总结
- [Java学习笔记]对象克隆
- hust 1328 String
- 【软件推荐】 AVAST! 全功能杀毒软件
- js中两个等于号和三个等于号的区别
- 取bundle 图片
- 取bundle 图片
- Leetcode 贪心 Best Time to Buy and Sell Stock
- 渠成-SEO最新案例解析
- LeetCode: Populating Next Right Pointers in Each Node