摘要: 大佬博客:https://blog.csdn.net/lee18254290736/article/details/77278769 对于正常的字符串模式匹配,主串长度为m,子串为n,时间复杂度会到达O(m*n),而如果用KMP算法,复杂度将会减少线型时间O(m+n)。设主串为ptr="ababaa 阅读全文
posted @ 2018-10-22 19:29 左手边五十米 阅读(541) 评论(0) 推荐(0) 编辑
摘要: Polycarp is working on a new operating system called BerOS. He asks you to help with implementation of a file suggestion feature. There are n files on 阅读全文
posted @ 2018-10-22 10:59 左手边五十米 阅读(242) 评论(0) 推荐(0) 编辑
摘要: Polycarp has a lot of work to do. Recently he has learned a new time management rule: "if a task takes five minutes or less, do it immediately". Polyc 阅读全文
posted @ 2018-10-22 10:48 左手边五十米 阅读(353) 评论(0) 推荐(0) 编辑