Stacks and Iterators
Lyft's phone screen often uses small problems with a stack or a cursor inside. One of the three here is the one candidates mention most, and it has been handed out as a stub with test cases already sitting in the shared pad.
The other two are shorter class builds. You'll have time to run all three.
Both of those are classes, so before you write a method, say what each call is allowed to assume. Keep whatever a later call needs next to the data, so no call has to search, and when a search can't be avoided, do it once and keep the result.
All three run against the same tests in Python, JavaScript, C++, Java, Go and Ruby. Feed each one repeated values before you trust it, since a repeated value breaks a lot of first drafts.
LyftPremium lesson · Coding round
The 3 Lyft problems are below.
- A Premium questionCoding · Medium · Signature problem
- A Premium questionCoding · Medium
- A Premium questionCoding · Medium
Each with hints, the follow-up and a tested solution.
Get the Lyft questions$49 a year · all 100 companies · cancel anytime
From 20,000+ candidate reports, forum threads behind logins and write-ups in Chinese.
Lyft interview guideKnow what Lyft asks before you walk in.
28 coding · 2 system design · 12 behavioral questions
Get their questions first.
InterviewLegend is independent and not affiliated with or endorsed by any company it covers.