
Manacher’s Algorithm – Finding all sub-palindromes in $O(N)$
1. Statement Given string $s$ with length $n$. Find all the pairs $(i, j)$ such that substring $s[i\dots j]$ is a palindrome. String $t$ is […]
1. Statement Given string $s$ with length $n$. Find all the pairs $(i, j)$ such that substring $s[i\dots j]$ is a palindrome. String $t$ is […]