After many referrals, a recruiter finally contacted me for an L62 position. This followed several rounds of interviews over two weeks.
Round 1: Duration: 60 mins | DSA + LLD
The interview began with a brief introduction and discussion of my previous work. This was followed by a DSA question on graphs, a variation of the Course Schedule II problem. I used a Topological Sort with DFS. The next part involved discussing the approach to a problem similar to Meeting Rooms II (only the approach was requested), followed by an LLD focusing on class and database structure. This was more conversational.
Self-assessment: Strong Yes
Round 2: Duration: 1 hr 15 mins | DSA + LLD
DSA question: Insert Delete GetRandom O(1)
LLD question: Design a terminal-based prompt for creating and updating files and directories (supporting mkdir, cd, and touch commands).
` My approach:
File class representing File/Folder Driver class to drive commands
The challenge was handling folder names with absolute, relative, and paths starting with ~. I used the Chain of Responsibility pattern. `
Self-assessment: Strong Yes
Round 3: Duration: 1 hr 15 mins | LLD + HLD
Design a Windows search functionality with these requirements:
For the LLD, the focus was on class design and search logic. Here's a summary:
` class Driver:
class FileSystem:
class File:
class Index:
invertedIndex: { "search_term" : [File, Position(-1 in case of folder name), frequency] }
searchIndex("term"): return map[term]
updateOrBuildindex():
`
The HLD discussion covered building an inverted index, updating it asynchronously via a daemon process, and searching the index.
Self-assessment: Average/Below-average (I couldn't fully justify my HLD approach, and the interviewer seemed unsatisfied)
Round 4: Duration: 1 hr 30 mins | LLD + HLD
Discussion on LRU and LFU caches (no code, but approach was expected). I was comfortable with LRU but not LFU, requiring several iterations to reach a solution. The LLD focused on creating an abstract class for common elements.
HLD question: Design a notification system similar to Unicommerce, where an Amazon seller is notified of competitor price changes on Flipkart (assuming no Flipkart API).
My Approach: Discussed web scraping to capture prices (including a brief discussion on robots.txt). Simple SQL DB design to store product prices for each competitor. Notifications are generated when scraped data differs from existing data.
The discussion centered on the optimal DB design. I preferred storing prices per seller; the interviewer preferred a simpler list format without seller information. We reached an agreement.
Self-assessment: Strong Hire
Round 5: Duration: 30 mins | HM round with simple HLD
After a 15-minute Q&A, the HLD question was designing a distributed logging system. The interviewer looked for an asynchronous logging approach.
Self-assessment: Hire
Observations: All interviewers were friendly and focused on approach and thought process over the solution.
Preparation Strategy:
DSA: I code in Python. I used (for the question list) and Greg Hogg's Python solutions. I also used editorials. I documented my solutions on GitHub and maintained shorter notes for complex approaches or new concepts.
LLD: I focused on OOP concepts and SOLID principles. I used a design patterns resource for Python.
HLD: I focused on database basics (using a course on educative.io), system design (using Grokking Modern System Design), and Jordan's YouTube channel. I created comprehensive notes for revision.
It's important to stay focused and work on weaknesses. Good luck!