Deloitte interview question

2. Write a program to check if a String is palindrome or not.