给定一个字符串求出其中最长个公共回文串. 举列子: abab -->回文串长度为2 以前的算法诸如: 扩展kmp求法过于麻烦,看到有一篇博文(http://leetcode.com/2011/11/longest-palindromic-substring-part-ii.html),写了一个关于这样的算法,按耐不住自己内心的小激动,就去学了下,于是将自己学习的一点点的理解记录下来: 它的处理方法是: 对于这样一个字符串: abab: a b a b 我们对于每一个字符串的进行逐个…
I - O'My! Gym - 101350I Note: this is a harder version of Mirrored string I. The gorillas have recently discovered that the image on the surface of the water is actually a reflection of themselves. So, the next thing for them to discover is mirrored…