Although hierarchical clustering is quadratic, we can efficiently exploit the agglomerative process as the most similar terms will merge into clusters first.
to identify the k most similar terms, we can exit the clustering process as soon as a cluster of size k is established.