hiho week 266 register

Ended

Participants:62

Verdict:Accepted
Score:100 / 100
Submitted:2019-08-04 18:56:40

Lang:G++

Edit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include<iostream>
#include<cmath>
#include<algorithm>
//
//O(n^3)
//O(n^2logn)2R
//nlogn便
using namespace std;
double R;
int N;
struct point {
    double x; double y;
    point(double a, double b) :x(a), y(b) {}
    point() = default;
};
point A[2005];
double dis(const point &a, const point &b)
{
    return sqrt(pow(a.x - b.x,2) + pow(a.y - b.y,2));
}
point getheart(const point &a, const point &b)
{
    if (dis(a, b) == 2 * R)
        return point(a.x - b.x, a.y - b.y);
    else
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX