Mphasis interview question

They asked me to write a program to reverse a string and explain its time complexity.