Pick top k most frequently occuring words from a huge string in O(n)