![](https://img-blog.csdnimg.cn/20201014180756913.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
KMP
Aloof__
笔记是记忆的缓冲
展开
-
牛客小白月赛28 G 牛牛和字符串的日常(KMP)
G 牛牛和字符串的日常 题目描述 牛牛每天都要做的事就是读书,从书里找自己喜欢的句子,他每天都会去读一本书,如果牛牛今天读的书的某连续{}kk个字符刚好是牛牛喜欢句子的某个前缀,那么牛牛将得到{}kk点兴奋感,但他每天只能注意到一次自己喜欢的句子(也就是每天只能增加一次兴奋感),也就是说他会尽量去找那个让自己兴奋度增加最多的句子,那么,{}nn天之后牛牛总共最多能有多少兴奋感? 输入描述: 第一行是一个字符串s(∣s∣<=1×105)表示牛牛喜欢的字符串第二行是一个整数n,表示总共经历..原创 2020-09-20 10:15:21 · 269 阅读 · 0 评论 -
秦皇岛 J MUV LUV EXTRA(KMP)
J - MUV LUV EXTRA One day, Kagami Sumika is stuck in a math problem aiming at calculating the length of a line segment with given statements and constraints. Since Sumika has no idea about it, she takes out a ruler and starts to measure the length. Unfo.原创 2020-09-20 09:57:05 · 253 阅读 · 0 评论