Track the First Unique Restaurant in a Stream

Read the full interview experience this question came from →

Quick Overview

Track integer restaurant IDs in arrival order and answer each query with the earliest value seen exactly once so far, or `-1` when no unique value remains.

Track the First Unique Restaurant in a Stream

Company: DoorDash

Role: Software Engineer

Category: Coding & Algorithms

Difficulty: medium

Interview Round: Onsite

Overview: Track integer restaurant IDs in arrival order and answer each query with the earliest value seen exactly once so far, or `-1` when no unique value remains.

Read the full DoorDash Software Engineer interview experience this question came from

|Home/Coding & Algorithms/DoorDash
DoorDash logo
DoorDash
May 26, 2026
mediumSoftware EngineerOnsiteCoding & Algorithms
3
0
Loading...

Submit Your Answer to Earn 20XP

Sign in to leave a comment

Loading comments...