Google Senior EM coding interview questions
These are the 14 coding questions YourAlly has tagged for Google at Senior EM. Senior EM (M2) is the level where you manage other managers.
A coding round at a large tech company usually runs 45 to 60 minutes with one or two problems. You write code that runs, test it on your own examples and state its time and space cost. Manager loops include less coding, but you still need to reason about code and review it well.
Practice a mock Google Senior EM coding loopPractice Google coding questions
Serialize and Deserialize Binary TreeFree to read
Design an algorithm to serialize and deserialize a binary tree. Serialization is the process of converting a data structure into a string so it can be stored or transmitted. Deserialization is the process of converting that string back into the original data structure. You must ensure that a tree can be serialized and then deserialized back to the same structure.
Example 1: Input: root = [1,2,3,null,null,4,5] Output: After serialize and deserialize, the tree is [1,2,3,null,null,4,5]
Example 2: Input: root = [] Output: []
Constraints: 0 <= number of nodes <= 200000 -1000 <= Node.val <= 1000
13 more coding questions
- Binary Tree Level Order Traversal Locked
- Group Anagrams Locked
- Invert Binary Tree Locked
- Longest Substring Without Repeating Characters Locked
- Median of Two Sorted Arrays Locked
- Merge Two Sorted Lists Locked
- Top K Frequent Elements Locked
- Trapping Rain Water Locked
- Two Sum Locked
- Valid Anagram Locked
- Word Ladder Locked
- Check if Palindrome Locked
- Contains Duplicate Locked
Related pages
More Google Senior EM rounds
- System design 16 questions
- Behavioral 19 questions
- Project retrospective 14 questions
Google coding at other levels
- L5 14 questions
- SDE-3 14 questions
- L6 14 questions
- Principal 14 questions
- L7 14 questions
- Senior Principal 14 questions
Other companies at this level
- Airbnb Senior EM 4 questions
- Anthropic Senior EM 4 questions
- Apple Senior EM 4 questions
- LinkedIn Senior EM 4 questions
- Meta Senior EM 14 questions
- Microsoft Senior EM 4 questions