Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
居然1A 计算几何也能1A?inline bool ck () { int ans (0); for (int i = 1; i <= top; i ++) { int t1 = cross (*stk[i + 1] - *stk[i], *stk[i + 2] - *stk[i + 1]); int t2 = cross (*stk[i + 2] - *stk[i + 1], *stk[i + 3] - *stk[i + 2]); if (t1 != 0 && t2 != 0) return false; ans += t1 + t2; } if (ans == 0) return false; return true; } Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator