Index Engines interview question

reverse a string