Unthinkable interview question

Reverse a string can be done using set or hashmap