Netcracker Technology Interview Question

Write code for a palindrome and reverse a string