上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 27 下一页
摘要: 赤裸裸的,需要注意的是这题是无向图,有重边,且起点可能与终点相同,这些是容易WA的地方。/* * hdu2112/win.cpp * Created on: 2012-8-2 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#includ 阅读全文
posted @ 2012-08-02 12:09 moonbay 阅读(147) 评论(0) 推荐(0)
摘要: /* * hdu2184/win.cpp * Created on: 2012-8-2 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set>#include <map>#include &l 阅读全文
posted @ 2012-08-02 11:11 moonbay 阅读(169) 评论(0) 推荐(0)
摘要: /* * hdu2175/win.cpp * Created on: 2012-8-2 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set>#include <map>#include &l 阅读全文
posted @ 2012-08-02 02:40 moonbay 阅读(166) 评论(0) 推荐(0)
摘要: 其实很简单,只要对KMP的next数组的含义能理解的话,就没有问题了。/* * hdu3746/win.cpp * Created on: 2012-8-2 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set 阅读全文
posted @ 2012-08-02 01:36 moonbay 阅读(195) 评论(0) 推荐(0)
摘要: 这题纯属蹭过,按理说应该是扩展KMP的方法。我是直接用的KMP的next数组,特殊情况加以判断就过了。/* * hdu4300/win.cpp * Created on: 2012-8-1 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue> 阅读全文
posted @ 2012-08-01 23:40 moonbay 阅读(164) 评论(0) 推荐(0)
摘要: 蛋疼的题目,测试数据都没说清楚,都想骂出题人了。细节部分好理解,就是模拟,打完以后不敢交,不知道测试数据中的1是啥,上网搜解题报告,居然没有,再一看过题数,63,我了个去。。。无奈只好自己试了,试了几次后发现1是测试数据总数。。。瀑布汗。。。/* * hdu1504/win.cpp * Created on: 2012-7-31 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#i 阅读全文
posted @ 2012-08-01 00:11 moonbay 阅读(257) 评论(0) 推荐(0)
摘要: /* * hdu1869/win.cpp * Created on: 2012-7-31 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set>#include <stack>#include 阅读全文
posted @ 2012-07-31 20:31 moonbay 阅读(124) 评论(0) 推荐(0)
摘要: 按题目描述的数据量,暴力是不可能过的,居然过了,太假了。。。/* * hdu1238/win.cpp * Created on: 2012-7-31 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set> 阅读全文
posted @ 2012-07-31 01:47 moonbay 阅读(139) 评论(0) 推荐(0)
摘要: 数据量很少,暴搜就可以过了/* * hdu1181/win.cpp * Created on: 2012-7-30 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set>#include <map& 阅读全文
posted @ 2012-07-30 16:14 moonbay 阅读(153) 评论(0) 推荐(0)
摘要: 简单题,暴搜就可以过了。/* * hdu4152/win.cpp * Created on: 2012-7-28 * Author : ben */#include <cstdio>#include <cstdlib>#include <cstring>#include <cmath>#include <ctime>#include <iostream>#include <algorithm>#include <queue>#include <set>#include <map&g 阅读全文
posted @ 2012-07-28 12:48 moonbay 阅读(284) 评论(0) 推荐(0)
上一页 1 ··· 9 10 11 12 13 14 15 16 17 ··· 27 下一页