码迷,mamicode.com
首页 >  
搜索关键字:palindrome    ( 1561个结果
Palindrome(poj1159)(动态规划)
Palindrome Time Limit: 3000MS   Memory Limit: 65536K Total Submissions: 53877   Accepted: 18610 Description A palindrome is a symmetrical string, that is, a string read i...
分类:其他好文   时间:2014-12-09 00:39:26    阅读次数:179
UVA 401-Palindromes(模拟)
Palindromes Time Limit:3000MS     Memory Limit:0KB     64bit IO Format:%lld & %llu Submit Status Description A regular palindrome is a string of numbers or letters that is the same for...
分类:其他好文   时间:2014-12-08 09:21:11    阅读次数:187
leetcode Palindrome Partitioning
把一个字符串划分成几个回文子串,枚举所有可能的划分例如For example, givens="aab",Return[ ["aa","b"], ["a","a","b"] ]写一个子函数判断是否为回文。然后dfs,这个dfs比之前的稍微难理解一些。dfs函数每次输入的起点代表之前已经处理好了,从这...
分类:其他好文   时间:2014-12-08 02:03:17    阅读次数:128
hdoj 1513 Palindrome 【LCS】+【滚动数组】
Palindrome Time Limit: 4000/2000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 3265    Accepted Submission(s): 1130 Problem Description A palindrome is...
分类:编程语言   时间:2014-12-07 20:23:16    阅读次数:220
[Leetcode] Palindrome Partitioning II
这是LeetCode上的一道题目,求出对于一个string,至少切多少刀可以让所有的substring都是回文串。原题是 https://oj.leetcode.com/problems/palindrome-partitioning-ii/Given a string s, partition s...
分类:其他好文   时间:2014-12-07 16:24:04    阅读次数:215
LeetCode: Palindrome Partitioning II 解题报告
Palindrome Partitioning IIGiven a string s, partition s such that every substring of the partition is a palindrome.Return the minimum cuts needed for ...
分类:其他好文   时间:2014-12-06 22:52:25    阅读次数:291
[leetcode]Palindrome Number
问题描述: Determine whether an integer is a palindrome. Do this without extra space. 基本思路: 考虑到回文的特点,根据给定数字获得与给定数字低位高位反序的数字。如果是回文数,则两数想等;否则不等。(即使反序数字溢出,也可的到正确结果) 代码: bool isPalindrome(int x) { //...
分类:其他好文   时间:2014-12-04 20:04:19    阅读次数:159
UVA 10739 String to Palindrome(DP)
In this problem you are asked to convert a string into a palindrome with minimum number of operations. The operations are described below:   Here you’d have the ultimate freedom. You are allowed to:...
分类:其他好文   时间:2014-12-04 01:03:49    阅读次数:138
leetcode[125] Valid Palindrome
判断一个字符串是不是回文,忽略其中的非数字和非字母,例如符号和空格不考虑。For example,"A man, a plan, a canal: Panama"is a palindrome."race a car"isnota palindrome.Note:Have you consider ...
分类:其他好文   时间:2014-12-04 00:53:19    阅读次数:227
[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: Panama" is a palindrome. "race a car" is not a ...
分类:其他好文   时间:2014-12-03 23:34:37    阅读次数:396
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!