Document word counter for CS211