Virtusa interview question

code reverse of string program in python or java