How to Find the Top-K Items: Heap and Streaming Approaches in Go

Finding the top K items in a dataset pops up everywhere: from highlighting the hottest posts in a social feed, to detecting the largest transactions in a financial system, or spotting the heaviest use

By · · 1 min read
How to Find the Top-K Items: Heap and Streaming Approaches in Go

Source: freeCodeCamp.org

Finding the top K items in a dataset pops up everywhere: from highlighting the hottest posts in a social feed, to detecting the largest transactions in a financial system, or spotting the heaviest use