Sad Love Story Time Limit: 40000/20000 MS (Java/Others) Memory Limit: 131072/65536 K (Java/Others)Total Submission(s): 16 Accepted Submission(s): 2 Problem Description There's a really sad story.It could be about love or about money.But love wi…
Problem Description Have you ever played quoit in a playground? Quoit is a game in which flat rings are pitched at some toys, with all the toys encircled awarded.In the field of Cyberground, the position of each toy is fixed, and the ring is carefull…
传送门 题意:给出$N$个点,求其中周长最小的三角形(共线的也计算在内).$N \leq 2 \times 10^5$ 这道题唤起了我对平面最近点对的依稀记忆 考虑平面最近点对的分治,将分界线两边的求解改为求三角形的最小边长即可. 小心坐标乘积爆int 不难但就是想不出 //This code is written by Itst #include<bits/stdc++.h> #define int long long #define ld long double #define eps (…
题目链接 Tricky Function $f(i, j) = (i - j)^{2} + (s[i] - s[j])^{2}$ 把$(i, s[i])$塞到平面直角坐标系里,于是转化成了平面最近点对问题. #include <bits/stdc++.h> using namespace std; #define rep(i, a, b) for (int i(a); i <= (b); ++i) #define dec(i, a, b) for (int i(a); i >=…
Description After successive failures in the battles against the Union, the Empire retreated to its last stronghold. Depending on its powerful defense system, the Empire repelled the six waves of Union's attack. After several sleepless nights of thin…
传送门: http://acm.hdu.edu.cn/showproblem.php?pid=1007 Quoit Design Time Limit: 10000/5000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 62916 Accepted Submission(s): 16609 Problem Description Have you ever played…