Amazon Interview Experience For A SDE-2

Back in 2017, I was working at a startup that was struggling to secure its next round of funding. With financial obligations piling up, I decided it was time to move on. I reached out to a recruiter at Amazon who had been involved in my previous Amazon interview process in 2016 when I received an offer for an L3 role. Unfortunately, I found out that he had left Amazon, so I contacted a few random technical recruiters at Amazon on LinkedIn. Thankfully, one of them responded and asked about my availability for an interview. I requested at least two weeks to prepare, which he agreed to.

At that time, Amazon was actively recruiting and holding hiring events on weekends. If you were invited for an in-house interview, you had to go to their office and complete all the interview rounds in a single day. They even provided lunch for all the candidates. I fondly remember those face-to-face interactions, which have since been replaced by virtual online interviews post-COVID. I miss those in-house interviews.

My Preparation:

Just two weeks before my interview, I dived back into Data Structures and Algorithms (DSA). I started by tackling recently asked Amazon interview questions. I knew that each round of an Amazon interview delves into one or two Amazon Leadership Principles, so I made sure to integrate them into my preparation.

I wasn’t aware of system design resources back then, so I caught up by delving into Amazon’s system design interview questions from w3wiki and LeetCode, discussing them with mentors and friends. I also compiled notes to articulate my projects and highlight compelling situations from my career, which helped me prepare for situational-based questions related to Amazon Leadership Principles. I even did a few mock interviews to polish my skills.

My Interviews:

Screening Round

The recruiter provided a HackerEarth link containing three coding questions to be solved within 1.5 hours. Familiar with platforms like HackerEarth and HackerRank, I knew the types of problems typically presented in screening rounds. It was crucial to solve the problems within the specified time limit and ensure that all test cases passed. I managed to solve all the problems in time.

Two days later, the recruiter sent an email inviting me for an onsite interview at the Bagmane office in Bengaluru.

Round 1: Coding and Problem Solving (1 hour)

  • Question 1: Longest Valid Parentheses
    • I initially proposed a brute-force approach, examining every possible substring for validity, which resulted in an overall complexity of O(N³). The interviewer requested a more efficient solution and provided a few hints. I then devised an O(N) solution using a stack. However, when asked to solve this problem without using additional space, I couldn’t come up with a solution using constant space.
  • Question 2: Rotate Image
    • I initially solved this problem using additional space equal to the size of the matrix. The interviewer then asked if it could be done in place. Despite giving it considerable thought, I couldn’t devise a constant space algorithm. Due to time constraints, the interviewer asked me to implement the solution I had provided.

Round 2: Coding and DSA (1 hour)

  • Question 1: Construct Binary Tree from Preorder and Inorder Traversal
    • The interviewer asked if we could recover a binary tree if we had the in-order traversal data. I explained that to recreate a general binary tree, we need in-order traversal along with either post-order or pre-order traversal. I successfully implemented the solution during the interview.
  • Question 2: Partition List
    • This was an interesting question about LinkedIn. After working through multiple examples, I provided a working solution and quickly converted it into code after verifying my approach with the interviewer.

Round 3: System Design (1 hour)

  • Question: Design Uber
    • The interview involved an in-depth discussion about handling a sudden increase in cab demand from a particular location. We also covered low-level design, discussing API architecture and database schema for an Uber-like platform. The open-ended nature of the discussion allowed me to showcase my technical skills and knowledge in building distributed, high-traffic systems.

Round 4: Bar Raiser Coding and Low-Level Design

  • Question 1: Minimum Window Substring
    • I started with a basic solution, but as the interviewer provided more examples, I realized it wasn’t simple. I eventually figured out that a sliding window approach was needed. After a few attempts, I found a solution that worked for all cases and wrote the code.
  • Question 2: LRU Cache
    • I shared my approach to implementing the LRU cache using Interfaces and Generics to make it adaptable for any Key and Value types. The interviewer was helpful and granted me an extra 10 minutes, which allowed me to complete the code with a few minor corrections.

Round 5: Hiring Manager

This round felt more like a casual conversation than a formal interview. The interviewer asked about my interests, past experiences, and notable projects. There were also three situational questions aimed at addressing Amazon’s leadership principles, such as dealing with conflicts with a manager and prioritizing tasks between operational excellence and business requirements.

The Offer

A few days later, the recruiter called to congratulate me on my success in the Amazon interview. I received favourable ratings, with two strong hires and three hires. Considering competing offers from a startup and PhonePe, I shared the details with the recruiter. Based on this information, the recruiter presented an initial offer that appealed to me, leading to my acceptance. Consequently, I joined Amazon as an SDE-2.

Key Takeaways:

  1. Amazon interviews: Aim to solve two problems within the 1-hour timeframe.
  2. Leadership principles: Interviewers keenly observe and assess your alignment with Amazon’s leadership principles during both technical problem-solving and general conversation.
  3. Flexibility in timing: Amazon interviewers may offer additional time if you’re on the right track, but this can vary between different interviewers.

Contact Us