Agility Kata „Word Count III“
The application can be started with a filename to read the text from instead of entering it manually. If no filename is provided, the application will still ask for a text. Sample usage:
1 2 3 | $ wordcount mytext.txt Number of words: 4 $ |
With mytext.txt being:
1 2 3 | Mary had a little lamb |