Exercise 1-11

How would you test the word count program? What kinds of input are most likely to uncover bugs if there are any?

This exercise is rather open-ended, so answers could vary quite a bit. Here are some ideas for test cases, most of which are related to whitespace because the program revolves around it: