摘要:
/*凸包:1.选取最左下边的点p02.根据剩余的m点集Q相对p0的极角排序,如果极角相同,只考虑最远的点3.对堆栈进行初始化 push(p0,S) push(p1,S) push(p2,S) for i=3 to m do the angle formed by points next_to_top(s) top(s) and pi make a nonleft turn do pop(S) PUSH(pi,S) return S*/ /*struct point{ double x,y;};bool mult(point p0,point p1,point p2){ ... 阅读全文