![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
hdu
Daniel Too
这个作者很懒,什么都没留下…
展开
-
HDU 1241 Oil Deposits 简单DFS
题目:(来源于hdu oj 官网)Problem DescriptionThe GeoSurvComp geologic survey company is responsible for detecting underground oil deposits. GeoSurvComp works with one large rectangular region of land at a time, and creates a grid that divides the land into numero原创 2020-09-29 21:30:34 · 76 阅读 · 0 评论 -
HDU 1010 Tempter of the Bone DFS剪枝、判断
HDU 1010 Tempter of the Bone DFS剪枝、判断1.最后的code较蠢但是ac了fine;2.本题采用dfs,但是直接无脑容易Time Limit Exceeded,so要进行优化;–2补充.dfs一般都要用visited和depth;3.用到图,我用了邻接矩阵所以程序庞大显蠢;4.优化的点主要有:(1)事先根据网格的S到D的最短距离判断能否在T内到达,不能then直接输出NO;(2)再利用奇偶剪枝,从https://www.cnblogs.com/yinbiao/原创 2020-09-29 18:47:45 · 72 阅读 · 0 评论 -
hdu 1002 A+B 2大数相加
hdu 1002 A+B 2大数相加1.注意输入直接用字符串输入;2.注意看清题目;3.特别小心自增自减的使用,避免使用到不合理的值;4.利用测试不断优化程序。#include<iostream>using namespace std;int main(){ int n; char m[1005], p[1005]; cin >> n; for (int i = 0; i < n; i++) { cin >> m >>原创 2020-07-26 00:37:36 · 76 阅读 · 0 评论