摘要:
1.利用叉积的正负来作cmp.(即是按逆时针排序). bool cmp(const point &a, const point &b)//逆时针排序 { point origin; origin.x = origin.y = 0; return cross(origin,b,origin,a) bool cmp(const Point& p1, const Point& p2)//360度范围逆时针排序 { complex c1(p1.x,p1.y),c2(p2.x,p2.y); return arg(c1) b.x; if (a.y == ... 阅读全文
摘要:
#define DeBUG#include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std ;#define zero {0}#define INF 2000000000#define EPS 1e-6typedef long long LL;const double PI = acos(-1.0);inline int s... 阅读全文