Super palindromes
Very easy
Execution time limit is 3 seconds
Runtime memory usage limit is 128 megabytes
The palindrome is a string with a length greater than one character that reads the same both from right to left and left to right. A superpalindrome is a string that can be represented as the concatenation of one or more palindromes.
You are given a string . Find the number of substrings in that are superpalindromes.
Input
The string that consists of a sequence of lowercase Latin letters with a length from to , without spaces.
Output
Print a single integer — the number of substrings of the string that are superpalindromes.
Examples
Input #1
Answer #1
Input #2
Answer #2
Submissions 1K
Acceptance rate 40%