码迷,mamicode.com
首页 >  
搜索关键字:palindrome    ( 1561个结果
poj1159——回文,lcs
poj1159——回文,lcsPalindromeTime Limit:3000MSMemory Limit:65536KTotal Submissions:54621Accepted:18892DescriptionA palindrome is a symmetrical string, tha...
分类:其他好文   时间:2015-03-21 06:21:20    阅读次数:160
Palindrome Number
Determine whether an integer is a palindrome. Do this without extra space.click to show spoilers.Some hints:Could negative integers be palindromes? (i...
分类:其他好文   时间:2015-03-20 12:19:32    阅读次数:132
HackerRank - Play with words
Kinda similar with another palindrome DP from LeetCode. Feel it, it is a bottom-up DP - palindrome subsequence.str = input()slen = len(str)dp = [[0 fo...
分类:其他好文   时间:2015-03-20 06:45:44    阅读次数:107
ural 1297 Palindrome(Manacher模板题)
转载请注明出处:http://www.cnblogs.com/fraud/ ——by fraud求最长回文子串。http://acm.timus.ru/problem.aspx?space=1&num=1297Manacher模板题,复杂度O(n),做这题纯属是为了验一下自己写的模板是否正确。当然这...
分类:其他好文   时间:2015-03-20 01:22:43    阅读次数:202
URAL 1297. Palindrome(输出最长回文子串--后缀数组)
Input The input consists of a single line, which contains a string of Latin alphabet letters (no other characters will appear in the string). String length will not exceed 1000 characters. Outpu...
分类:编程语言   时间:2015-03-19 22:09:51    阅读次数:176
LeetCode——Valid Palindrome (回文判断)
Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example,"A man, a plan, a canal: Pan...
分类:其他好文   时间:2015-03-18 12:07:14    阅读次数:111
leetcode题解||Palindrome Number问题
problem: Determine whether an integer is a palindrome. Do this without extra space. click to show spoilers. Some hints: Could negative integers be palindromes? (ie, -1) If you are thinking of conv...
分类:其他好文   时间:2015-03-17 22:00:59    阅读次数:163
Valid Palindrome
Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example, "A man, a plan, a canal: Panama" is a palindrome. "race a car" is no...
分类:其他好文   时间:2015-03-16 17:48:39    阅读次数:117
判断一个数字是否为回文数
Determine whether an integer is a palindrome. Do this without extra space.(source)判断一个数字是否为回文数,并且不使用额外的存储空间。“回文”是指正读反读都能读通的句子,那么回文数,就很容易理解,就是指一个数正反读的值是相同的。还有一个要求是不要使用额外的存储空间。Hints: 要将一个数的最高位与最低位比较,取出一...
分类:其他好文   时间:2015-03-16 17:45:42    阅读次数:142
Valid Palindrome
判断一个字符串是否是对称的 跳过所有非数字和字母,字母不分大小写 知道函数isalnum和tolower或者toupper就可以做了,两个指针一个指向头,一个指向尾,朝中间靠拢比较 空串是对称的 class Solution {public: bool isPalindrome(string s) ...
分类:其他好文   时间:2015-03-16 16:13:52    阅读次数:150
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!