coffeescript ver of word frequency