码迷,mamicode.com
首页 >  
搜索关键字:partitioning    ( 428个结果
leetcode Palindrome Partitioning II
Given a string s, partition s such that every substring of the partition is a palindrome.Return the minimum cuts needed for a palindrome partitioning ...
分类:其他好文   时间:2014-10-20 07:33:59    阅读次数:234
leetcode dfs Palindrome Partitioning
Palindrome Partitioning  Total Accepted: 21056 Total Submissions: 81036My Submissions Given a string s, partition s such that every substring of the partition is a palindrome. Return all...
分类:其他好文   时间:2014-10-13 11:18:20    阅读次数:173
Palindrome Partitioning[leetcode] DFS以及DP的解法
第一种方法是DFS,将所有可能的前缀找到,递归调用partition(剩余字符串) 复杂度为O(2^n) 代码如下: vector> partition(string s) { vector> res; vector patition; if (s.size() == 0) return res; partition(s...
分类:其他好文   时间:2014-10-10 01:33:23    阅读次数:464
【uva-11584】Partitioning by Palindromes(dp)
粗略的复杂度是L^3,长度最大是1000,,没敢做,之后发现其实这个复杂度的系数也不大,可以过,而且很快。 dp[j] = dp[i - 1] + 1 (if(str[i] ~ str[j]为回文) 14327451 11584 Partitioning by Palindromes Accepted C++ 0.052 2014-10-...
分类:其他好文   时间:2014-10-09 20:14:17    阅读次数:164
leetcode -- Palindrome Partitioning II
[问题描述]Given a strings, partitionssuch that every substring of the partition is a palindrome.Return the minimum cuts needed for a palindrome partitioni...
分类:其他好文   时间:2014-10-07 01:23:32    阅读次数:341
leetcode -- Palindrome Partitioning
谋事在人,成事在天[问题描述]Given a strings, partitionssuch that every substring of the partition is a palindrome.Return all possible palindrome partitioning ofs.F...
分类:其他好文   时间:2014-10-07 00:28:22    阅读次数:232
Palindrome Partitioning
[leetcode]Given a string s, partition s such that every substring of the partition is a palindrome....
分类:其他好文   时间:2014-10-06 12:19:50    阅读次数:200
Palindrome Partitioning II
【leetcode】Given a string s, partition s such that every substring of the partition is a palindrome.Return the minimum cuts needed for a palindrome partitioning of s....
分类:其他好文   时间:2014-10-06 12:12:00    阅读次数:149
Leetcode: Scramble String
Given a string s1, we may represent it as a binary tree by partitioning it to two non-empty substrings recursively.Below is one possible representatio...
分类:其他好文   时间:2014-10-05 04:01:47    阅读次数:232
[leetcode] Scramble String @python
Given a strings1, we may represent it as a binary tree by partitioning it to two non-empty substrings recursively.Below is one possible representation...
分类:编程语言   时间:2014-09-30 02:51:41    阅读次数:394
428条   上一页 1 ... 33 34 35 36 37 ... 43 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!