摘要: 题目大意:按逆时针方向连接个点,并将其输出,第一个点为(0,0)。 题目思路:叉积排下序就好了 #include<cstdio> #include<cstdlib> #include<cmath> #include<iostream> #include<algorithm> #include<cst 阅读全文
posted @ 2016-11-04 15:44 声声醉如兰 阅读(138) 评论(0) 推荐(0) 编辑
摘要: 题目大意:建立围墙将城堡围起来,要求围墙至少距离城堡L,拐角处用圆弧取代,求围墙的长度。 题目思路:围墙长度=凸包周长+(2*PI*L),另外不知道为什么C++poj会RE,G++就没问题。 #include<cstdio> #include<cstdlib> #include<cmath> #in 阅读全文
posted @ 2016-11-04 15:40 声声醉如兰 阅读(306) 评论(0) 推荐(0) 编辑
摘要: 转自:http://blog.csdn.net/y990041769/article/details/38258761 首先在二维坐标下介绍一些定义: 点:A(x1,y1),B(x2,y2) 向量:向量AB=( x2 - x1 , y2 - y1 )= ( x , y ); 向量的模 |AB| = 阅读全文
posted @ 2016-11-04 14:15 声声醉如兰 阅读(278) 评论(0) 推荐(1) 编辑