| 6 | ll d1() { return x + y; } |
| 7 | ll d2() { return x - y; } |
| 8 | ll dist(point other) { |
| 9 | return abs(x - other.x) + abs(y - other.y); } |
| 10 | bool operator <(const point &other) const { |
| 11 | return y == other.y ? x > other.x : y < other.y; } |
| 12 | } best[MAXN], arr[MAXN], tmp[MAXN]; |