Sopra Steria Interview Question

How to write code for palandrome.