Wednesday, April 11, 2012

Remove String

Today's mishap of the day:

Dim newSentence As Char
versus
Dim newSentence As String

That was all it took to make the program mess up. Head-shaking. The program's objective is to, given a sentence and a phrase to remove from that sentence, remove that phrase. For example, if you type "I dislike vegetables," and remove "dis," the new statement should read "I like vegetables." The error above meant only "I" showed up in the new statement.

No comments:

Post a Comment