摘要: #include using namespace std; const int maxn = 3010; string s; int dp[maxn][maxn]; int main() { cin >> s; int len = s.length(); memset(dp, 0, sizeof(dp)); for(int i = len - 1; i >=... 阅读全文
posted @ 2019-04-29 16:36 丧心病狂工科女 阅读(295) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=3068 Problem Description 给出一个只由小写英文字符a,b,c...y,z组成的字符串S,求S中最长回文串的长度.回文就是正反读都是一样的字符串,如aba, abba等 Input 输入有多组c 阅读全文
posted @ 2019-04-29 15:34 丧心病狂工科女 阅读(110) 评论(0) 推荐(0) 编辑