Longest palindrome substring
/***Compute the longest palindrome substring ***/ #include <iostream> #include <string> using namespace std; bool isPalindrom(string str, int start, int end) { if (start == end || start > end) return true ; while (start != end && start < end) { if (str[start] != str[end]) return false ; else { start += 1; end -= 1; } } ...