摘要: http://acm.hdu.edu.cn/showproblem.php?pid=254 0-1背包问题 代码: #include<stdio.h> #include<string.h> #include<algorithm> using namespace std; int cmp(int a, 阅读全文
posted @ 2014-11-29 21:55 wojiaohuangyu 阅读(7) 评论(0) 推荐(0)
摘要: 正好我现在在玩数独这个游戏,看到这个问题我就来了兴趣,完成着这个问题,妈妈再也不用担心我玩数独游戏啦~~ 题目链接: http://acm.nyist.net/JudgeOnline/problem.php?pid=722 #include<stdio.h> int map[9][9]; int f 阅读全文
posted @ 2014-11-29 21:27 wojiaohuangyu 阅读(8) 评论(0) 推荐(0)
摘要: 题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1010 做这道题目的时候需要注意剪枝,如果没有剪枝的话,就会超时 注意奇偶剪枝 代码:】 #include<stdio.h> #include<string.h> #include<stdlib.h> c 阅读全文
posted @ 2014-11-29 11:00 wojiaohuangyu 阅读(8) 评论(0) 推荐(0)
摘要: 题目链接:http://acm.nyist.net/JudgeOnline/problem.php?pid=58 比较简单的搜索题目, 代码: #include<stdio.h> #include<string.h> int map[9][9]={{1,1,1,1,1,1,1,1,1},{1,0,0 阅读全文
posted @ 2014-11-29 10:51 wojiaohuangyu 阅读(6) 评论(0) 推荐(0)