CGI interview question

Write a for loop that reverses a string.