![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
想法
sunrainchy
这个作者很懒,什么都没留下…
展开
-
HDU 4723 How Long Do You Have to Draw
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4723这个题目要求的是最多的三角形,其实只要所有点都连了基本上就是最大了,我们要考虑的主要是最小想想要想最大的话每个点都一定会连,而且一定是从左向右,因为不能相交嘛,那么就想办法使总长度最小首先毫无疑问的是第一个点一定与第一个点相连,然后看程序中的while循环,下面的步骤要么是x++,要原创 2013-09-12 18:40:18 · 1737 阅读 · 0 评论 -
HDU 4739 Zhuge Liang's Mines
题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=4739这次网络赛的一个简单题,我没出,坑了队友其实思路是对的,但是比较乱,也没想到是背包,结束之后接着按照原先的思路去做竟然AC了!先暴力找出所有正方形,然后寻找其中点不相交且正方形最多的以个子集,由于最多就是五个,所以直接for循环了!#include #include #in原创 2013-09-16 10:21:23 · 870 阅读 · 0 评论 -
HUST 1624 Beautiful Sky(判断两图形是否相同)
Beautiful SkyTime Limit: 1 Sec Memory Limit: 128 MBSubmissions: 8 Solved: 3DescriptionThe 8th(2013) ACM Programming Contest of HUST Problem SetLittle Mine is a naughty boy. He was once a原创 2013-12-18 12:21:47 · 1011 阅读 · 0 评论 -
HUST 1003 Sibonacci Numbers(杂题)
题目链接:http://acm.hust.edu.cn/problem.php?id=1003As is known to all, the definition of Fibonacci Numbers is:f(1)=1f(2)=1f(n)=f(n-1)+f(n-2) (n>=3)Now Sempr found another Numbers, he named it原创 2013-12-20 13:01:33 · 991 阅读 · 0 评论 -
HUST 1025 Sequence(递归 + 重复计算消除)
题目链接:http://acm.hust.edu.cn/problem.php?id=1025Consider the special sequence of numbers, which satisfies the following requirements: a[0] = 0; a[1] = 1; for every i = 1, 2, 3, ... a[2*i]原创 2013-12-20 20:57:39 · 764 阅读 · 0 评论 -
山谷(思维)
描述八百里伏牛山连绵不断,高低起伏。学习过数山谷的个数之后,小明想知道这些山谷中最多能装多少水。我们用竖直的矩形表示山的高度,如图:我们用这样一种形式来表示上图的山:[6 1 4 6 7 5 1 6 4],每个数字代表山的高度。假如连日暴雨,爆发山洪,这些山之间的山谷能装多少水?规定用单位1的方块来计算容积。所以,在上边的图中下标原创 2013-12-21 10:55:04 · 858 阅读 · 0 评论