TraceLink interview question

Write a code for string reversal.