The Meta "Flavor"
Meta interviews are about Speed and Correctness. They typically give you 2 Medium/Hard problems in 45 minutes. You are expected to write production-ready code with minimal bugs. The patterns often focus on Hashing, Sliding Windows, and Iterative Tree Traversal.
The Top 15 Must-Know Problems
| Category | Problem | Key Pattern |
|---|---|---|
| Array Squeeze | Trapping Rain Water | Two Pointers |
| Binary Search | Median of Two Arrays | Partition BS |
| Monotonic | Sliding Window Max | Monotonic Deque |
| Tree Traversal | Vertical Order Traversal | BFS + Column Map |
| Strings | Minimum Window Substring | Variable Window |
| List Logic | Reverse Nodes in K-Group | Pointer Surgery |
| DP Matrix | Maximal Rectangle | Monotonic Stack |
| Hashing | Palindrome Pairs | Trie / Reverse Hash |
| Heaps | Merge K Sorted Lists | Min-Heap |
| Intervals | Insert Interval | Linear Scan |
| Recursion | Word Search II | Trie + DFS |
| Parsing | Basic Calculator II | Operator Stack |
| Search | K-th Largest Element | QuickSelect / Heap |
| Streams | Find Median Stream | Two Heaps |
| Graph Logic | Number of Islands | DFS / BFS |
Meta Interview Tips:
- Coding Speed: Don't spend more than 5 minutes on the approach. Get to the code.
- Dry Run: Always dry run your code with a small example (e.g.,
n=1ork=2) before saying you're finished. - Space Trade-offs: Meta loves HashMaps. If you can trade $O(N)$ space for $O(1)$ time, do it.