Microsoft Interview Question

String manipulation (replace certain characters in a string with other characters) + edge cases !!! I was asked to walk through my code, identify all edge cases, and modify my code if it was not robust enough.