Interview Structure
The first 5 minutes were spent on introductions between the two interviewers and me.
- Operating Systems and Computer Science Fundamentals
The interviewer started with a rapid-fire round of OS and computer science fundamentals.
Questions covered:
What is a page, virtual memory, and a page fault?
What is thrashing?
What are mutexes and semaphores?
Binary semaphore vs. mutex: What is the difference, and when should you use each?
What is a cache? What are the different caching strategies?
Write-Through vs. Write-Back caching: What is the difference, and when should you use each? - Object-Oriented Programming and C++ Fundamentals
The interviewer asked whether I knew Java so that he could ask Java-specific questions. I declined and mentioned that my primary experience was with Go and C++.
He then went quite deep into OOP and C++ concepts, covering:
What are templates?
What are virtual functions and pure virtual functions?
Struct vs. class.
What are friend functions? Can they access private and protected members?
Can virtual, static, and friend functions be combined? Why or why not?
Why do we need virtual functions?
What are const member functions?
What are static members?
What are destructors and virtual destructors? Why do we need virtual destructors?
UDP vs. TCP: What are the differences, and when should you use each? - Behavioural and Project Discussion
The interviewer asked me to explain my best project in detail.
Questions included:
Explain the project and your individual contribution.
What were the major technical challenges you faced?
How did you identify and resolve those challenges?
Explain the overall system design.
What alternative approaches did you consider?
What were the trade-offs between the different approaches?
The discussion focused on understanding the technical depth of my project and the reasoning behind my design decisions. - Data Structures and Algorithms
I was asked only one DSA question.
Question: Design a data structure that supports the following operations in O(1) time complexity.
bool get(T val);
bool put(T val);
T removeRandom();
The interviewer asked me to implement a generic version using C++ templates.
Follow-up 1: What if duplicate insertions are allowed?
We discussed two possible interpretations:
Every unique value should have an equal probability of being selected.
Every occurrence of a value should have an equal probability of being selected, meaning duplicates increase the probability of that value being returned.
5. Questions for the Interviewer
The last 10 minutes were reserved for asking questions to the interviewers.
Overall Experience
I had gone through several previous interview experiences and was expecting two LeetCode medium-level problems along with some OS-related questions.
However, I was quite taken aback by the breadth and depth of the questions asked. The interview covered a wide range of fundamentals, including Operating Systems, C++, OOP, networking, caching, project deep dives, and DSA.
My biggest takeaway: Don't prepare exclusively for DSA. Be thorough with CS fundamentals, especially OS and OOP, and be prepared to discuss your projects in considerable technical depth.
Discussion
Loading comments…