Crossover for Work interview question

Write functions for palindrome, equilibrium index.