InterviewDB Question

Game Ranking: Design a Real-Time Leaderboard System with Score Updates and Rank Queries

Question Details

Problem Design a leaderboard system for a multiplayer game that supports: updating a player's score, querying a player's current rank (1-indexed, rank 1 = highest score), and fetching the top K players. Scores can only increase. Example: Clarify: Does add_score replace the score or add to it? Follow-ups How would you implement get_rank efficiently -- what data structure supports O(log n) rank queries (e.g., sorted set, order-statistics tree)? How does Redis's ZSET (sorted set) solve this problem…

Full Details

🔒

Unlock all Rubrik questions

Full insider details, leaked discussions, and candidate experiences.

Get full access — $100 a year, unlimited access

About This Question

This is a reported interview question from a rubrik interview during the phone round.

It covers the following topics: Coding, Onsite, Phone .