Open In App

Amazon Interview Experience for SDE

Last Updated : 01 Oct, 2020
Like Article

PPI after 2 months Internship

Amazon conducted Interviews at the end of last summer Internship for SDE roles. Unlike previous years it was completely Work from Home and thus interviews were conducted to better judge the candidature of interns for full-time conversion at the end of the 2-month internship.

There were 2 rounds of interviews in the last week of the internship and the first round interviewer was an SDE and the second-round interviewer was a senior manager. Both rounds were conducted through amazon chime and a two-way code editor was used.

Round 1: In this round, the interviewer focused on coding skills/problem-solving skills. 

  • The interview began with a brief introduction from my end and then the interviewer jumped to my CV and asked to explain the projects that I had in 2nd year, and I was caught off guard as I wasn’t prepared for it. I tried to explain as much as I could but he wasn’t satisfied with the explanation.
  • Next, he asked me Maximum sum triplet and I gave a brute force solution to it and I coded it and then he asked me to optimize it. I suggested 2 methods, one with sort and the other with taking 3 variables(most optimized approach). He asked me which sort I would use and I told merge sort and then he asked me to write merge sort where I struggled and ended up only explaining the approach. Later, I coded the most optimized approach.

Round 2: In this round, the interviewer focused more on the DS/Algo proficiency.

  • My first question was a very typical one and I couldn’t solve it.
    Ques: There are two amazon centers, one in Bangalore and one in Hyderabad where the candidates need to go for interviews. A candidate needs to visit one of the centers and the expense would be on amazon. Each location needs to have half of the candidate(N, candidate number is even) and the cost associated with the travel expense needs to be minimized. Output the cost.
    Ex: For 6 candidates {20,40}, {10,60}, {5,80}, {60,10}{100,15}, {150,20}. Here lets assume cost is given {Bangalore, Hyderabad} thus first 3 candidates should go to Bangalore and next 3 should go to Hyderabad and total cost is 70.
  • The second question was transforming BST to Greater sum tree, which was fairly easy and less time-consuming to write.
  • The third question was to implement an audio/song player where there are n songs and needs to be played in a randomized order and a played song must not be repeated until all the unrepeated songs have been played. It was my first time with these questions and I struggled little with this. I gave 2-3 approaches with different data structures to implement it. Later, the interviewer told me to try this without any extra space as I was using O(n) space with using DS and the given form was an array/array list. Then, I suggested a two-pointer approach to it. One pointer(p1) would indicate the songs in the right are unplayed and another pointer(p2) to access the songs in this right to end range randomly and play and then swap that song with the p1’s immediate right song and then increment p1 by 1 thus including that song in played portion. If all the songs have been played the rest both pointers to 1st element and now the songs can be repeated.

My performance was not up to mark as I made some mistakes during the 2 rounds of interview, and I was not offered a full-time role.

Like Article
Suggest improvement
Share your thoughts in the comments

Similar Reads