Hacker News new | ask | show | jobs
by tantalor 767 days ago
Ah then that's the classic "merge k sorted streams" question. It's a good question and easy to solve in a coding interview. Good candidate should be able to solve in about 30 minutes. My favorite solution goes something like "put values in a heap and then read them back out" because you only need to read 1 value from each stream at a time.
1 comments

Yep, that was my same approach as well.