given a generic text - checks if its palindrome or not