Amazon Interview Experience for SDE | 2-Months Internship(On-Campus)
Amazon visited our campus (NIT Jamshedpur) on 3rd October. It consisted of 2 Rounds ( 1 Online Assessment and 1 Technical Interview)
Round 1: Round 1 was an online assessment that consisted of four parts:
Code Debugging: 7 questions to be debugged in 20 minutes.(Difficulty – Easy)
Coding Test: 2 coding questions to be solved in 70 minutes.
- Longest Common Subsequence
- Given a matrix with r rows and c columns, find the maximum score of a path starting at [0, 0] and ending at [r-1, c-1]. The score of a path is the minimum value in that path. For example, the score of the path 8 → 4 → 5 → 9 is 4. Don’t include the first or final entry. You can only move either down or right at any point in time.(https://leetcode.com/discuss/interview-question/383669/)
Input: [[1, 2, 3] [4, 5, 1]] Output: 4 Explanation: Possible paths: 1-> 2 -> 3 -> 1 1-> 2 -> 5 -> 1 1-> 4 -> 5 -> 1 So-min of all the paths = [2, 2, 4]. Note that we don't include the first and final entry. Return the max of that, so 4.
Workstyle assessment (Scaling your ability with respect to different situations and characteristics): 20 minutes
Reasoning ability: 35 minutes
Out of 150+ students, 30 students were selected for round 2. I was one of them.
Round 2: Technical Interview (It was held on 25th of October)
First, the interviewer introduced himself and told me to introduce myself. Then he jumped to coding questions as given.
- There was a family of ants. We need to find if it is a GOOD or BAD family. (Note: A GOOD family is that in which all the interactions between the ants takes place in opposite gender)
Input : 3 3 (3 ants, 3 interactions) 1 2 (1 interacts with 2 and vise versa) 2 3 3 1
The interviewer just showed me the questions and didn’t tell anything else, even though I asked him to explain. I have to find the output of the above test case and code accordingly. After 10 mins of thinking, I told him that if we can divide the graph into two parts then we can say that the family is GOOD else BAD. (https://www.geeksforgeeks.org/bipartite-graph/)
He asked me to proceed with the code and I wrote the code on the given text editor then he checked it and didn’t say anything and moved to the second question.
- The second question was to find the distance between the two farthest nodes in a graph.
I told him the brute force approach, he asked me to optimize my code. I tried to optimize the code, but he told me that we were running out of time and if I have any questions. I asked one question about the scope of Deep Learning on Amazon. And then we left the meeting and the interview was over.
The result was announced on the very next day. Among 30 students 10 were selected for the internship and thankfully I was one of them.
Though I didn’t receive any acknowledgment from the interviewer neither he explained the question much but I gave him the best answer I could, and I was pretty confident and satisfied with my given answers in the limited time.
Will suggest you prepare and give your 100% and leave the rest. All the very best!