随笔分类 -  基本算法

摘要:就是断断续续刷了一些银组的题,虽说真的有点水,因为这些题大多是简单转化一下模型就可以了,但还是有一些启示吧 bzoj1618 完全背包的方程要理解好 1 #include<cstdio> 2 #include<cstring> 3 #include<algorithm> 4 using namesp 阅读全文
posted @ 2017-11-01 21:56 Vincent_hwh 阅读(178) 评论(0) 推荐(0)
摘要:最近效率不高不低吧,在写usaco的题,然而真的很水==也没什么可以放上来的东西 边复习一下其他模板 KMP http://www.matrix67.com/blog/archives/115 利用i,j两个指针检索两个字符串:s1[i-j+1..i]==s2[1..j] s1[i+1]!=s2[j 阅读全文
posted @ 2017-10-18 21:41 Vincent_hwh 阅读(151) 评论(0) 推荐(0)
摘要:感觉自己像个智障 直接bfs 然而读入没判负号查了半小时。。 1 #include<cstdio> 2 #include<cctype> 3 #include<cmath> 4 #include<cstring> 5 #include<algorithm> 6 using namespace std 阅读全文
posted @ 2017-09-09 12:14 Vincent_hwh 阅读(214) 评论(0) 推荐(0)
摘要:无脑码农题== 烦的是很多细节,把几个主要过程分开写,化整为零会清楚很多 1 #include<cstdio> 2 #include<cstring> 3 #include<cmath> 4 #include<algorithm> 5 using namespace std; 6 #define m 阅读全文
posted @ 2017-08-23 22:06 Vincent_hwh 阅读(166) 评论(0) 推荐(0)