[LinkedIn] Find the 100 most frequently occurring words in a set of documents.
CareerCup 看到的解答:
1. Get count of each word.
2. Create a MIN heap of word counts with 1st 100 elements.
3. Now for all other word counts , if count is smaller (OR equal) than root (of max heap), ignore it, otherwise replace the root with new greater count and heapify.