Arista Networks interview question

How would you detect palindromes?