随笔分类 -  字符串

摘要:51NOD 1277:http://www.51nod.com/onlineJudge/questionCode.html#!problemId=1277 跟HDU 6153还挺像的:http://www.cnblogs.com/Egoist-/p/7435573.html 相比与上面那个题,这个还 阅读全文
posted @ 2017-08-26 16:58 #Egoist# 阅读(392) 评论(0) 推荐(1)
摘要:HDU6153:http://acm.hdu.edu.cn/showproblem.php?pid=6153 Orz 果然字符串很神奇……(神奇到人哭出来啊TAT)果然算法理解的不够透彻的话,是无法灵活运用的QAQ 其实只要简单的改一点点KMP的地方…… KMP的next[i]存储的是模式串下标0至 阅读全文
posted @ 2017-08-26 16:04 #Egoist# 阅读(793) 评论(2) 推荐(2)
摘要:HDU1251:http://acm.hdu.edu.cn/showproblem.php?pid=1251 初学字典树,码模板…… HDU 2846 http://acm.hdu.edu.cn/showproblem.php?pid=2846 字典树原本是按前缀搜索的,题中所要求查询的并不一定是字 阅读全文
posted @ 2017-08-25 18:53 #Egoist# 阅读(239) 评论(0) 推荐(0)
摘要:HDU 3068 http://acm.hdu.edu.cn/showproblem.php?pid=3068 HDU 3294http://acm.hdu.edu.cn/showproblem.php?pid=3294 感觉DP相对实现起来更简洁一些,很容易想到,可以用bool dp[i][j]: 阅读全文
posted @ 2017-08-24 15:43 #Egoist# 阅读(209) 评论(0) 推荐(0)
摘要:Given two strings a and b we define a*b to be their concatenation. For example, if a = "abc" and b = "def" then a*b = "abcdef". If we think of concate 阅读全文
posted @ 2017-08-23 15:11 #Egoist# 阅读(223) 评论(0) 推荐(0)
摘要:The little cat is so famous, that many couples tramp over hill and dale to Byteland, and asked the little cat to give names to their newly-born babies 阅读全文
posted @ 2017-08-23 14:43 #Egoist# 阅读(137) 评论(0) 推荐(0)