Usually Amazon SDE-2 interviews happens in 2 days schedule. On the 1st day there will be 3 rounds (PS/DS and design rounds). If the feedback is good you then will be called for remaining 2 rounds which are Manager and Bar raiser.
In my case date of joining was very close in some other org, so all 5 rounds happened on one day.
Round 1 PS/DS:
Q1.
Given a binary tree you have to print endmost node in zig zag fashion.
Example:
1
/ \
2 3
/ \ / \
4 5 6 7
\
8
Output should be : 1, 3, 4, 8
Soln: Level Order traversal using node count approach and using flag to decide which node end you have to print (leftmost or rightmost)
Q2. Given snake and ladder board you have to find minimum no. of move required to reach end of board.
Soln: BFS (link https://www.geeksforgeeks.org/snake-ladder-problem-2/)
Round 2: PS/DS
Q1) Given following piece of code and two int arrays A & B of equal size n, explain what is it doing.
ans = 0;
for(int i=0;i<n;i++)
for(int j=0;j<n;j++)
for(int k=0;k<n;k++){
if(A[i]!=B[i] && A[j] ! = B[k] && A[k]!=B[k]){ ans = max(ans, A[i] + A[j] + A[k]);}
}
Sol’n: Basically this code is finding max sum triplet from A array such that value in those indexes of B array is different.
Next he asked me to re write this code with better time complexity.
Q2. Given a binary tree, find path in the tree such that the sum of nodes in path is equal to given K. Path can start from any nodes and can end on any nodes.
1
/ \
2 3
/ \ / \
4 5 6 7
\
8
Example : for k = 10, there will be 2 paths: 1->3-> 6 and 3->7
Use following concept:
https://www.geeksforgeeks.org/find-subarray-with-given-sum/
https://www.geeksforgeeks.org/find-subarray-with-given-sum-in-array-of-integers/
Round 3: Design
Design Dominoes website. This was mainly focused on High level design and you have to mention all the major components like Delivery tracking system, User Signup/Login flow, Fulfillment service etc.
You have to describe complete flow of a order until its delivery to customer.
Interviewer also asked me to write schema details for few entities.
Round 4: Manager
In the first of half of this round we mostly discussed about my work experience and role which is played in my current team.
In the second half he asked me to design Job management system where user submits a job and specify the time its should run just like Airflow app.
Round 5: Bar raiser
This one was mostly discussion oriented to judge on the basis of Amazon leadership principles. You have to mention few scenarios about your work and how you have applied those leadership principles.
Few questions which I remember were why did I used Golang instead of Java, most challenging tasks which I have worked on.
Finally, after few days I received positive feedback from HR.
Recommended Posts:
- Amazon Interview Experience | Set 154 (For SDE2)
- Amazon Interview Experience | Set 260 (For SDE2)
- Amazon Interview experience | Set 324 (For SDE2)
- Amazon Interview Experience | Set 381 (For SDE2)
- Amazon Interview Experience | Set 430 (For SDE2)
- Amazon Interview Experience | Set 431 (For SDE2)
- Amazon Interview Experience SDE2
- Amazon Interview Experience for SDE2
- Interview Experience of Amazon - SDE2
- Amazon Interview Experience for SDE2 (3 years exp)
- Amazon Interview Experience for SDE2 | 3+ years Experienced
- Walmart Interview Experience for SDE2 | Set 19 (3.8 years experience)
- Flipkart Interview Experience | Set 28 (For SDE2)
- Groupon Interview Experience | Set 4 (SDE2 for Experienced)
- Microsoft Interview experience | Set 114 (2.5 Years Experienced for SDE2)
- OYO Rooms Interview Experience | Set 5 (For SDE2)
- ixigo Interview Experience | For SDE2 Backend
- Traveloka Interview Experience for SDE2
- Flipkart Interview Experience for SDE2 (2.5 yr Exp.)
- Interview Experience for SDE2 at OneDirect
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.


