Windows, Scans & Intervals
Uber's array questions often start with a nested loop that already works. You walk out from every point until you hit a blocker, recompute the max and min of every stretch, or square everything and sort. Each version passes the sample. Then the interviewer asks for the linear version and adds a twist on top. Expect to give the brute force and its cost first, then the faster version, with time and space at each step.
None of the first three problems needs an unusual data structure. Each fast answer keeps one value alive across the pass instead of recomputing it for every element, like the position of the last blocker you passed, the current max and min held at the front of two deques, or the next-smallest absolute value on each side of zero. Name that value before you code and the loop is easy to write. The interval problems that follow use the same single pass after one sort by start time.
UberPremium lesson · Coding round
The 5 Uber problems are below.
- A Premium questionCoding · Medium · Signature problem
- A Premium questionCoding · Medium · Frequently asked
- A Premium questionCoding · Medium · Frequently asked
+ 2 more in this lesson
Each with hints, the follow-up and a tested solution.
Get the Uber questions$49 a year · all 100 companies · cancel anytime
From 548 Uber reports, forum threads behind logins and write-ups in Chinese.
Uber interview guideKnow what Uber asks before you walk in.
30 coding · 4 system design · 21 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.