Problem:
Let be a word. Define a substring of to be a word of the form , for some pair of positive integers . Show that has at most distinct palindromic substrings.
For example, aaaaa has 5 distinct palindromic substrings, and abcata has 5 ().
Problem:
Let be a word. Define a substring of to be a word of the form , for some pair of positive integers . Show that has at most distinct palindromic substrings.
For example, aaaaa has 5 distinct palindromic substrings, and abcata has 5 ().
Solution:
For each palindrome substring appearing in , consider only the leftmost position in which it appears. I claim that now, no two substrings share the same right endpoint. If some two do, then you can reflect the smaller one about the center of the larger one to move the smaller one left.