| 16 | } |
| 17 | |
| 18 | double ccw(const point& a, const point& b, const point& c) { |
| 19 | return (b.x - a.x) * (c.y - a.y) - (b.y - a.y) * (c.x - a.x); |
| 20 | } |
| 21 | |
| 22 | double polar_angle(const point& origin, const point& p) { |
| 23 | return std::atan2(p.y - origin.y, p.x - origin.x); |