Keysight Technologies Interview Question

How to reverse a string