Bloomberg interview question

Reverse a string