题目链接:
题意:
给定n个点,用n个点组成的多边形中(可以是凹多边形,但n个点一定要全在多边形上)
在所有能由n个点构成的多边形中
求最小面积的多边形的周长 - 最小周长。
思路:
首先我们选择一个定点,则接下来的数进行一个排列,有(n-1)!个排列。
这个序列相邻两个数之间有一条线段。
判断多边形合法:任意两条线段不相交即可。n^2
剩下就是简单的更新答案了。
所以复杂度是...
分类:
其他好文 时间:
2014-12-07 01:23:21
阅读次数:
207
http://www.delphibasics.co.uk/RTL.asp?Name=Outhttp://stackoverflow.com/questions/14507310/whats-the-difference-between-var-and-out-parametersA var par...
Difference between stem and lemma(wiki)先标记下Stemis the part of the word that never changes even when morphologically inflected, whilst a lemma is the b...
分类:
其他好文 时间:
2014-11-30 00:11:52
阅读次数:
231
Linux Kernel sys_call_table、Kernel Symbols Export Table Generation Principle、Difference Between System Calls Entrance In 32bit、64bit Linux
分类:
系统相关 时间:
2014-11-28 15:54:36
阅读次数:
952
http://stackoverflow.com/questions/6863182/what-is-the-difference-between-iterator-and-iterable-and-how-to-use-themIterator is an interface, which has...
分类:
编程语言 时间:
2014-11-28 15:51:39
阅读次数:
200
1) Dequeue can quickly insert or delete both at the front or the end. However, vector can only quickly insert or delete at the end.2) Memory allocatio...
分类:
编程语言 时间:
2014-11-28 14:15:34
阅读次数:
145
Adding a current-mirror circuit to a typical boost circuit allows you to select the amount of boost voltage and to ensure a constant difference betwee...
分类:
其他好文 时间:
2014-11-28 14:00:51
阅读次数:
128
You were given a gift—a talent or askill—that you can use to help empower yourself and eventually empower others.Make the most out of it by touching l...
分类:
其他好文 时间:
2014-11-26 11:01:35
阅读次数:
151
第24章 数值算法 24.1 递增赋值iota 24.2 元素求和accumulate 24.3 两序列元素内积inner_product 24.4 部分元素求和partial_sum 24.5 相邻元素求差adjacent_difference 24.6 n次方计算power 24.7 本章小结有...
分类:
编程语言 时间:
2014-11-25 14:16:51
阅读次数:
179
#include #include #include #include using namespace std;bool mycmp(const string& a, const string& b) { string ta = a + b; string tb = b + a; ...
分类:
其他好文 时间:
2014-11-25 00:12:26
阅读次数:
281