System Design · Karat · Easy
A game's leaderboard service has to support three operations: displaying the 100 highest-ranked players, looking up the score of a single player, and changing a player's score. The current implementation is too slow. Explain which data structures and algorithms you would use so that all three operations run efficiently, and discuss the trade-offs that come with your choices.