Altimetrik interview question

implement reverse string