My interview was a single online round, and it went straight into three LeetCode hard problems with no warm-up. The first was Longest Valid Parentheses, where I had to find the longest well-formed run of brackets in a string. That one can be approached with a stack or with dynamic programming, so the interviewer was looking at how I reasoned about the approach as much as the final code. The second was Merge k Sorted Lists. The standard solutions use a min-heap over the list heads or divide and conquer, and it's a problem where the complexity discussion matters as much as getting it to run. The third was Wildcard Matching, a dynamic programming problem over two strings where * and ? have to be handled correctly. All three problems are rated hard, and doing them in one sitting was the biggest challenge. There was little room to recover from a wrong turn on one problem before the next arrived. After the coding questions, the interview moved to core computer science fundamentals. I ended up declining the offer.
Prep tip from the candidate
Expect three LeetCode hard problems back to back in one online round, so practice solving hards under time pressure in a single session. Prioritize dynamic programming (wildcard matching), stack and string problems (longest valid parentheses), and heap-based merging (merge k sorted lists).
Source: Interview Query. AI-anonymized by the source and lightly edited for clarity.
Discussion
Loading comments…