随笔分类 -  凸包

二维凸包模板
摘要:#include<stdio.h>#include<math.h>#include<algorithm>#include<iostream>using namespace std;const int MAXN=1000;struct point{ int x,y;};point list[MAXN];int stack[MAXN],top;int cross(point p0,point p1,point p2) //计算叉积 p0p1 X p0p2 { return (p1.x-p0.x)*(p2.y-p0.y)-(p1.y-p0.y)*(p2 阅读全文

posted @ 2012-09-29 08:43 kuangbin 阅读(3073) 评论(0) 推荐(2) 编辑

POJ 1113 Wall (凸包)
摘要:WallTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 21502Accepted: 7048DescriptionOnce upon a time there was a greedy King who ordered his chief Architect to build a wall around the King's castle. The King was so greedy, that he would not listen to his Architect's proposals to build 阅读全文

posted @ 2012-04-13 13:24 kuangbin 阅读(3498) 评论(0) 推荐(1) 编辑

导航

JAVASCRIPT: