How to Design your Mock Interview Answers to nail your FAANG interviews

Once you develop your concepts, use this to get the best results

Devansh
Geek Culture
7 min readAug 15, 2021

--

To help me understand you fill out this survey (anonymous)

I woke up to some great news recently. One of my people (Student S)who had worked with me to improve their mock interview skills had sent me this DM on Instagram:

Microsoft is apparently the best place to interview. Multiple students have praised it

Naturally, this is very exciting. MS is a tech giant. What was especially notable to me about Student S was that he was an experiment. He came to me in a very interesting place. He had been practicing Leetcode for about a year and a half. And unlike other people who reach out to me, he was very good at it. He had a strong knowledge of the various data structures and algorithms. He also had the perfect mindset when it came to learning from questions. He was very interested in trying to understand the concepts, rather than just trying to learn the tricks to solve questions. For example, we spent quite a while discussing recursion, getting to recursion, examples from all over, and optimizing instead of just memorizing some set patterns to solve problems.

Now you might be wondering why this student came to me. Simply put, he wasn't able to translate his skills in an interview. So we decided to try something different. Something different to the approach that has worked to help people clear interviews at Facebook and Google. Different from what I did to get recommendations like this:

I have 2 articles on getting roles at top tech companies. “The 4 step method my students use to maximize Leetcode Problems and ace their FAANG Interviews” talks about how to maximize your returns on every Leetcode problem. “How I helped a non-Computer Science student nail a FAANG software dev job” is the step-by-step way I helped a non-CS student get a software developer role at Facebook. They both stress the importance of going over many problems. Typically I reserve one session/week where I help students go over their doubts/questions about those problems they come across. With Student S, I decided to spend all our time on mock interviews. The idea was simple. We had a month to prepare. His knowledge was at a pretty high level. So the highest ROI for us would come from making sure that S was able to ace his interview problems in an organized way. Keep in mind we focused mainly on hard and medium problems.

Following are the things we focused on to heighten his interview performances.

Expect results by following this checklist

1. Edge/Base Cases

By far the easiest way to get started on any challenging coding problem. Look at the corner/edge cases and resolve them immediately. It can be as simple as checking for certain conditions and returning the appropriate values. But this is generally a good starting point. This is helpful not only in recursion but all kinds of complex problems.

Why do we do this first? Three reasons:

  1. Harder problems can get pretty overwhelming. Solving the more obvious edge cases will get your mind warmed up to the main problem. The edge cases can give you a good launching-off point for your main problem. Taking the low-hanging fruit first will also get you going and give you momentum. This is crucial in a high-pressure situation like an interview.
  2. Often, what messes people up are edge cases. Many people try to solve the general problem first. As they do this, they end up missing the corner cases that need to be handled efficiently.
  3. These cases can provide a few hints. This is especially true for recursive problems.

I typically recommend that my students explore these cases while asking the interviewers clarifying questions. Clarifying questions, are questions about the constraints of the problem, that can often reveal certain attributes about the nature of the problem/solution.

2. Running through your hypothetical solution by hand

Imagine you had a working black box code. If you printed the state at each moment, what would it look like? Going through some simple cases by hand will help you get an intuition for how the problem might be solved. For example, let’s take a question where we must interleaf a stack with itself using only a queue. So a stack (1,2,3,4,5) becomes (1,5,2,4,3). Google loves this question. I was able to solve this question by just taking a small stack and running through what a solution would do. Not HOW (what we have to solve). Just WHAT it would look like. To see the full explanation of the process (and code) check out this video. The audio is slightly low, but it goes into the full solution for this problem:

Don’t forget to Like and Subscribe

This method is a way to avoid getting stuck. Imagine there’s a question that’s very hard. You have no idea how to proceed. Just working through some possible ways your code could work will allow your mind to focus. This is much better than sitting there and awkwardly scratching at a possible solution (or even worse, freezing up). Combined with your base cases, you might even be able to generate some pseudocode.

Writing Psuedocode/actual code

This is where your knowledge and practice come in handy. When you have worked out the “WHAT” of your solution, we can get to the HOW. You can chip off little pieces at a time, figuring out the solution incrementally. This is where practices like modularity and encapsulation are useful. There are no tricks to this section., so I won’t waste too much time on it. Nor should I have to tell you why this is important.

Exploring Tradeoffs

This is a section that a lot of people miss. However, this is something that can really set you apart. Imagine you have a working, efficient code. Now is when you can score a lot of brownie points with your interviewers. How? Start talking about other possible ways you would solve it. Could we solve it using another data structure. Could we increase time complexity, but save space? Are there alternative data structures that could be used. You don’t have to give specifics. This is where you can be high level. You’ve already demonstrated your technical implementation skills. Now is when you get bonus points for creativity and knowledge.

Closing

Using this checklist, you should do much better in your interviews. Try implementing this approach and share how it happened for you. You will definitely see better interview results from this.

As a disclaimer: To benefit from this you need a very strong base. You can develop this by studying online, using books, or even reaching out to me for tutoring.

Here is a text communication with a student J. J is a 15-year working professional, who struggled with even easy-medium Leetcode problems. We’ve been working together for about on and off for 2 months. Due to her hectic personal life, she can’t dedicate many hours to practice and often has to even cancel our scheduled classes. As of now, we’re taking a small hiatus as J handles some personal circumstances. However, in that time, she has been able to improve her problem-solving skills. Prior to our working together, she felt hopeless attempting the coding interview problems. Now, in her words, she is “slowly building logic.” I will provide many more examples later in the article.

Additionally, feel free to sign up for my newsletter. Here I break down various tech-related things, including various coding interview questions. I will start sharing questions and solutions more regularly there. This is a great way to make sure you can learn from my techniques if you can’t commit to tutoring. It is on my substack: https://devanshacc.substack.com/.

Reach out to me

If that article (or the recommendation) got you interested in reaching out to me, then this section is for you. You can reach out to me on any of the platforms, or check out any of my other content. If you’d like to discuss tutoring, text me on LinkedIn, IG, or Twitter. If you’d like to support my work, using my free Robinhood referral link. We both get a free stock, and there is no risk to you. So not using it is just losing free money.

Check out my other articles on Medium. : https://rb.gy/zn1aiu

My YouTube: https://rb.gy/88iwdd

Reach out to me on LinkedIn. Let’s connect: https://rb.gy/m5ok2y

My Instagram: https://rb.gy/gmvuy9

My Twitter: https://twitter.com/Machine01776819

My Substack: https://devanshacc.substack.com/

Live conversations at twitch here: https://rb.gy/zlhk9y

Get a free stock on Robinhood: https://join.robinhood.com/fnud75

--

--

Devansh
Geek Culture

Writing about AI, Math, the Tech Industry and whatever else interests me. Join my cult to gain inner peace and to support my crippling chocolate milk addiction