To make it seem more realistic, I'd make a map<char,vector<char>>
of appropriate 'substitution' keys based off of keyboard layouts (e.g. QWERTY). Basically, it seems more real if your typo is "responsw" than "responsl" since "w" and "e" are next to each other. You'll also want to randomly delete or insert letters too. I'd assign a frequency to "errors" and then a frequency of each kind of error.
Now that you've got this and the other answers handling the randomness aspect (if(rand(100)<5)
), you should be able to replicate the desired typo handler.