parses file and counts words in file