Simple typewriter program error
<p>So I am getting an error that doesn't seem to make any sense, and the solution is most likely staring at me in the face. I do understand the "String index out of range: XX", but it seems to change that value even if I input the same string multiple times. It says (unknown source) which I presume is the phrase variable? And I do see that the error is occurring at line 85, which prints the phrase. However, everything looks fine and dandy to my slightly-novice eye. Any wisdom to shed?</p>

<p>Source:</p>

<p><img src="http://i.stack.imgur.com/rBfnW.jpg" alt="Code"></p>

<p><a href="http://i.stack.imgur.com/rBfnW.jpg" rel="nofollow">Image Link</a>.</p>
