摘要: 题目链接:http://codeforces.com/problemset/problem/429/D 题目大意: 给定一个长度为 $n$ 的数列 $a_1, a_2, \ldots, a_n$。 用 $s$ 表示 $a$ 的前缀和数组,即 $s_i = \sum\limits_{j = 1}^i 阅读全文
posted @ 2023-03-28 22:48 quanjun 阅读(13) 评论(0) 推荐(0) 编辑
摘要: 题目大意:求平面最近点对。 解题思路:分治经典问题。 示例程序: #include <bits/stdc++.h> using namespace std; const int maxn = 2e5 + 5; struct Node { double x, y; } a[maxn], b[maxn] 阅读全文
posted @ 2023-03-28 22:33 quanjun 阅读(20) 评论(0) 推荐(0) 编辑