Problem Description
Given a string A, find the common palindromic sequence ( A sequence which does not need to be contiguous and is a pallindrome), which is common in itself.
You need to return the length of longest palindromic subsequence in A.
NOTE:
1 <= |A| <= 1005
First and only argument is an string A.
Return a integer denoting the length of longest palindromic subsequence in A.
Input 1:
A = "bebeeed"
Output 1:
4
Explanation 1:
The longest common pallindromic subsequence is "eeee", which has a length of 4
NOTE: You only need to implement the given function. Do not read input, instead use the arguments to the function. Do not print the output, instead return values as specified. Still have a question? Checkout Sample Codes for more details.