2016年7月24日

hdu 5747 最长上升子序列 (nlogn)

摘要: ac code: #include <iostream> #include <algorithm> #include <cstdio> #include <cstring> using namespace std; typedef long long ll; #define INF 1e9 #def 阅读全文

posted @ 2016-07-24 11:22 Tob's_the_top 阅读(165) 评论(0) 推荐(0) 编辑

hdu 5750

摘要: AC: 几乎一模一样但WA: 阅读全文

posted @ 2016-07-24 11:17 Tob's_the_top 阅读(112) 评论(0) 推荐(0) 编辑

2016年7月22日

SPOJ CPCRC1C Sum of Digits

摘要: 题目连接 题意:计算从a到b每个数每位数字相加的和 code: #include <iostream> #include <cstdio> #include <cstdlib> #include <cstring> using namespace std; typedef unsigned long 阅读全文

posted @ 2016-07-22 20:59 Tob's_the_top 阅读(199) 评论(0) 推荐(0) 编辑

2016年7月19日

hdu5289

摘要: 暴力: ST算法: 阅读全文

posted @ 2016-07-19 09:26 Tob's_the_top 阅读(90) 评论(0) 推荐(0) 编辑

2016年7月15日

codeforces 569A Music

摘要: 题目连接 歌曲下载速度ds = (q-1)/q 歌曲播放速度ps = 1 则当前已下载好s秒的情况下,歌曲播放进度追上下载进度是歌曲播放到的位置pp = s / (ps - ds) = s * (1 - (q-1)/q) = s*q; code: #include <iostream> #inclu 阅读全文

posted @ 2016-07-15 11:14 Tob's_the_top 阅读(220) 评论(0) 推荐(0) 编辑

2016年7月13日

poj1469 二分图匹配(匈牙利算法)

摘要: poj1469 course code: 阅读全文

posted @ 2016-07-13 23:08 Tob's_the_top 阅读(128) 评论(0) 推荐(0) 编辑

2016年7月12日

有向图的强连通分量

摘要: Kosaraju算法 阅读全文

posted @ 2016-07-12 00:14 Tob's_the_top 阅读(163) 评论(0) 推荐(0) 编辑

2016年7月10日

HDU 1429 (bfs+状态的位压缩)

摘要: hdu 1429 胜利大逃亡(续) 一共有10把钥匙,用10位的二进制反映钥匙的拥有情况 阅读全文

posted @ 2016-07-10 15:22 Tob's_the_top 阅读(138) 评论(0) 推荐(0) 编辑

hdu2531 (BFS)

摘要: hdu 2531 Catch him 块的BFS,以块中一点做搜索,其余点用相对该点的偏移值表示即可 阅读全文

posted @ 2016-07-10 15:16 Tob's_the_top 阅读(108) 评论(0) 推荐(0) 编辑

2016年6月3日

最小生成树 Kruskual和Prim算法

摘要: 最小生成树就是一个连通图的最小连通子集。 Kruskual算法: hdu1223 code: prim算法: hdu1102code: 阅读全文

posted @ 2016-06-03 23:15 Tob's_the_top 阅读(562) 评论(0) 推荐(0) 编辑

导航