added palindrome string algorithm