Guidewire Interview Question

Reverse a String and explain your thought process