← Questions

Streaming top-K frequent elements with O(1) updates

0
NvidiaCodingLast asked Sep 2026

A coding interview question asked in Nvidia's coding round, last asked Sep 2026. It tests streams, hash maps and linked lists.

Elements arrive one at a time from an unbounded stream (for example item ids from an event log). Design a structure that can report, at any moment, the k elements seen most often so far.

Sign in to unlock this question

The full prompt, the worked answer and your own canvas or code with the AI tutor. New accounts get 5 credits: each one unlocks a question for good.

Where it's asked

  • Nvidia · Coding · Last asked Sep 2026Live coding, often C++-leaning; each round usually opens with 10 to 15 minutes on your past work · Assume no AI unless the interviewer offers it

What it tests

streams · hash maps · linked lists · top-k

Your code and the AI tutor open when you unlock this question.