Deloitte interview question

program to check palindrome in javascript