Q31 Redis Domain 2 · 25–30% of exam Priority · Real Exam

Which data structure best fits a leaderboard requiring ranked retrieval by score?

  1. A Hash
  2. B Sorted Set (ZSET) (correct answer)
  3. C List
  4. D Set

Shortcut: Sorted sets maintain members ordered by score, supporting ZRANGE, ZREVRANK, and range queries in logarithmic time, which is exactly the leaderboard access pattern.