Amazon Interview Experience On Campus for SDE 1

Key Focus: MustDoCodingQuestion(GeeksForGeeks), HackerRank

Written Round:

2 coding questions and  30 MCQ’s on mettl Platform ( https://mettl.com/ ).
Total Time : 1.5 hr.



Coding Questions:
1.Minimum number of jumps to reach end ( https://www.geeksforgeeks.org/minimum-number-of-jumps-to-reach-end-of-a-given-array/ )
Solved in O(n) time complexity.
2. Count Inversions in an array ( https://www.geeksforgeeks.org/counting-inversions/ )
Solved using Merge Sort in O(nlogn) time complexity.

MCQ’s :
Questions on Trees(BST), Output Prediction of given Codes(Codes are given in C, C++  Languages).

In my case, I have solved both the coding questions with all test cases passed.

Round 1:

Introduction of both of us.

1.Asked about what Data Structure to implement HashMap other than bst, bbst, Heaps, Arrays.
Told about bst, bbst approaches and mentioned that I know implementation of these data structure approaches only, then he moved to next question.
2.Detect cycle in an undirected graph ( https://www.geeksforgeeks.org/detect-cycle-undirected-graph/ )
3.Find the first circular tour that visits all petrol pumps ( https://www.geeksforgeeks.org/find-a-tour-that-visits-all-stations/ )
4.Maximum Path Sum in a Binary Tree ( https://www.geeksforgeeks.org/find-maximum-path-sum-in-a-binary-tree/ )
5.Reduce the string by removing K consecutive identical characters ( https://www.geeksforgeeks.org/reduce-the-string-by-removing-k-consecutive-identical-characters/ )

For Question 3, 4 I had mentioned to interviewer that I already know the solution for those questions, so for that questions he only asked to explain logic to solve them without writing code.

For Question 2, 5 needed to write neat production code with all edge cases handled properly.

Round 2:

Introduction of both of us.


1.Efficient search in an array where difference between adjacent is 1 ( https://www.geeksforgeeks.org/efficient-search-in-an-array-where-difference-between-adjacent-is-1/ )
2.Asked to specify about all Normal Forms and why normal forms are used (DBMS).
3.Asked to specify process synchronization concept and ways to handle it and also asked to mention all the process scheduling algorithms.
4. LRU Cache Implementation ( https://www.geeksforgeeks.org/lru-cache-implementation/ )

For Question 1, 4 have to write neat production code with all edge cases handled properly.

Round 3:

Introduction of both of us.

1.In an n-array tree where each node can have an apple represented as 0(apple not present) or 1(apple present), then needed to find out path with maximum number of apples. Asked to optimize both time and space complexity.
Solved using Diameter of a Binary Tree technique with some modifications.

2. Given a bench with n seats and few people sitting, tell the seat number each time when a new person goes to sit on the bench such that his distance from others is maximum ( https://www.careercup.com/question?id=5385816814125056 ). Here he extended this question by specifying that I need to find k such positions for k persons to sit. Needed to solve in optimal way.
Solved this using Heap Concept.

3.Asked about Producer-Consumer problem in Operating System and the asked to write a neat code for both producer and consumer solving their synchronization problem using Synchronization Mechanism without busy waiting. And also asked to extend the code to work in distributed environment.

For Question 1, 2, 3 have to write neat production code with all edge cases handled properly.

Bar Raiser Round:

Introduction of both of us.


1.Check for Majority Element in a sorted array ( https://www.geeksforgeeks.org/check-for-majority-element-in-a-sorted-array/ )
Solved using Binary Search in O(logn) time.
2.Asked what happens when we enter a URL and how we are able to reach a site (Expected to explain about Domain Name System Concept).

For Question 1 have to write neat production code with all edge cases handled properly.

Note: For all the questions optimal solution is expected, hints are given if stuck to derive optimal solution. Similarly, for all the questions asked in interview they mentioned to write neat production code with all edge cases handled properly.

Verdict: I was Offered Full Time Employment (SDE 1) at Amazon.

Write your Interview Experience or mail it to contribute@geeksforgeeks.org



My Personal Notes arrow_drop_up

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.


Article Tags :
Practice Tags :


Be the First to upvote.


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.