(matlab)plot画图的颜色线型 ? ? ???y?????????黄色???????????·?????????????点线 ????m?????????粉红???????????○????????????...
分类:
其他好文 时间:
2014-09-27 14:16:10
阅读次数:
183
题意:从任意一个任意一个可走的点开始找一个最长的路,这条路如果有转弯的话, 那么必须是 90度,或者没有转弯! 思路: 首先用dfs将所有可走点开始的 8 个方向上的线段的最长长度求出来 ! step[i][j][k] 表示的是(i,j)沿着k方向一直走到头或者转弯时的最长步数! 最后枚举每一个可....
分类:
其他好文 时间:
2014-09-25 23:17:48
阅读次数:
204
题目链接:
huangjing
题意:
从图中任何一个点走,最多只能转90度的弯,并且只能转一次弯,求这个最长路。。
思路:
ym的朝鲜选手的代码,真厉害啊,它是每个点的8个方向都走一遍,然后最后遍历全图,去每个点最多转一次弯的最大长度,这个确实有点厉害,相当于枚举拐点。。
题目
Wang Xifeng's Little Plot
Time Limit: 2000/10...
分类:
其他好文 时间:
2014-09-24 20:11:31
阅读次数:
278
Wang Xifeng's Little Plot
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)
Total Submission(s): 319 Accepted Submission(s): 214
Problem Description
《D...
分类:
其他好文 时间:
2014-09-23 01:07:53
阅读次数:
301
HDU 5024 Wang Xifeng's Little Plot
题目链接
思路:先利用记忆化搜索预处理出每个结点对应8个方向最远能走多远,然后枚举拐点记录最大值即可
代码:
#include
#include
#include
using namespace std;
const int d[8][2] = {{-1, 0}, {0, 1}, {1, 0}, ...
分类:
其他好文 时间:
2014-09-22 18:56:23
阅读次数:
210
Problem Description
《Dream of the Red Chamber》(also 《The Story of the Stone》) is one of the Four Great Classical Novels of Chinese literature, and it is commonly regarded as the best one. This novel...
分类:
其他好文 时间:
2014-09-22 17:39:12
阅读次数:
209
http://acm.hdu.edu.cn/showproblem.php?pid=5024网络赛Wang Xifeng's Little PlotTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/65536 K (Java/Othe...
分类:
其他好文 时间:
2014-09-21 21:11:11
阅读次数:
371
一道好枚举+模拟题目。转换思维视角
这道题是我做的,规模不大N
但仔细一分析发现对每个点进行全部八个方向的遍历100X100X100^8 。100X100个点,每个点在走的时候8中选择,TLE
于是改为另一个角度:
以符合要求的点为拐弯点,朝两个垂直的方向走,求出最远的距离。这样只要对每个点各个方向的长度知道,组合一下对应的就OK。
避免了每个点深搜。
PS:搜索的时候x,y写...
分类:
其他好文 时间:
2014-09-21 01:21:09
阅读次数:
415
Wang Xifeng's Little Plot
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others)
Total Submission(s): 194 Accepted Submission(s): 131
Problem Description
《D...
分类:
其他好文 时间:
2014-09-21 00:12:19
阅读次数:
257
HDU 5024 Wang Xifeng's Little Plot (搜索)...
分类:
其他好文 时间:
2014-09-20 22:36:29
阅读次数:
248