Infosys Interview Question

Write a code to print whether the word accepted as input is a palindrome