Monthly Archives: May 2013

Palindrome Partitioning

Given a string s, partition s such that every substring of the partition is a palindrome. Return all possible palindrome partitioning of s. For example, given s = “aab”, Return [ [“aa”,”b”], [“a”,”a”,”b”] ] C++: 01 class Solution { 02 public: 03     bool isPalindrome(int i, int j, string … Continue reading

Posted in Array and linked list, Dynamic programming, String | Leave a comment