Skip to content

最长回文子串 马拉车算法 | Joke-Lin | BLOG #22

@Weijun-Lin

Description

@Weijun-Lin

https://joke-lin.top/2018/10/01/2018-10-01-manacher/

leetcode5:https://leetcode-cn.com/problems/longest-palindromic-substring/description/
可以自己提交看看对不对

暴力搜索
这个应该是最容易的方法了,但是一看复杂度O(n3),还是放弃好了。
但是这个方法也是遍历所有字符串字串的一种方法。下面是暴力搜索的代码:

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions