Amazon interview experience Real time questions & tips from candidates to crack your interview

SDE - 1

Amazon
upvote
share-icon
3 rounds | 3 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 8 months
Topics: Data Structures, Web development, System Design, Algorithms, Dynamic Programming, Database, OS, Networking, OOPS, DevOps
Tip
Tip

Tip 1 : For Data Structures number of questions doesn't matter. Try to understand the logic behind them and try to apply them in creating multiple scenario's. Learn them by heart. 
Tip 2 : For Web.Development Try to learn full stack development. See which part interests you more, Increase your knowledge horizon, Always try to build a system a system considering It will be served to millions of customers. By doing this 1-2 projects will increase and cover all the major things which one should learn in their career/college.

Application process
Where: Other
Eligibility: Good knowledge of Data Structures, Some great projects which are used by the users
Resume Tip
Resume tip

Tip 1 : Always try to make it a single page 
Tip 2 : Always make resume company specific. eg. Data Structures part more if you are applying for MNC's eg. Amazon, Google, DE Shaw, browserstack.

Interview rounds

01
Round
Medium
Online Coding Interview
Duration90
Interview date10 Aug 2019
Coding problem1

Interview started at 11:00 am. It was an online round. During the coding round I submitted optimized solution and got full acceptance of the solutions.

1. Detect Cycle In A Directed Graph

Moderate
30m average time
75% success
0/80
Asked in companies
MicrosoftAdobeAmazon

You are given a directed graph having ‘N’ nodes. A matrix ‘EDGES’ of size M x 2 is given which represents the ‘M’ edges such that there is an edge directed from node EDGES[i][0] to node EDGES[i][1].

Find whether the graph contains a cycle or not, return true if a cycle is present in the given directed graph else return false.

For Example :
In the following directed graph has a cycle i.e. B->C->E->D->B.

alt text

Note :
1. The cycle must contain at least two nodes.
2. It is guaranteed that the given graph has no self-loops in the graph.
3. The graph may or may not be connected.
4. Nodes are numbered from 1 to N.
5. Your solution will run on multiple test cases. If you are using global variables make sure to clear them.
Problem approach

In the first attempt I wrote down the optimized solution.

Try solving now
02
Round
Medium
Face to Face
Duration80
Interview date17 Aug 2019
Coding problem1

Interview started at 10:00 am. Interview went well, I was able to connect with the interviewer and enjoyed the whole interview

1. Given a string, find the next smallest palindrome

Easy
12m average time
80% success
0/40
Asked in companies
UberAmazonMakeMyTrip

You are given a number 'N' in the form of a string 'S', your task is to find the smallest number strictly greater than the given number 'N' which is a palindrome.

Note:

1) A palindrome is a word, number, phrase, or another sequence of characters that reads the same backward as forward, such as 'naman', 'abcba', '1234321', etc
2) The numerical value of the given string 'S' will be greater than 0.
3) A single-digit number is also considered as a palindrome.
4) Note that the length of the string 'S' is nothing but the number of digits in the number 'N'.
Problem approach

The question was new to me, I tried to figured out the optimal solution for it. While finding the solution, I got stuck and not able to get it through My interviewer gave me one hint and which helped me to get the optimized solution for it.

Try solving now
03
Round
Medium
Face to Face
Duration80
Interview date17 Aug 2019
Coding problem1

Interview started at 11:00 am. Interview went well.

1. Boundary Traversal

Hard
20m average time
85% success
0/120
Asked in companies
Goldman SachsOYOExpedia Group

You are given a binary tree having 'n' nodes.


The boundary nodes of a binary tree include the nodes from the left and right boundaries and the leaf nodes, each node considered once.


Figure out the boundary nodes of this binary tree in an Anti-Clockwise direction starting from the root node.


Example :
Input: Consider the binary tree A as shown in the figure:

alt text

Output: [10, 5, 3, 7, 18, 25, 20]

Explanation: As shown in the figure

The nodes on the left boundary are [10, 5, 3]

The nodes on the right boundary are [10, 20, 25]

The leaf nodes are [3, 7, 18, 25].

Please note that nodes 3 and 25 appear in two places but are considered once.
Problem approach

1. In the start we were discussing difference between graphs and tress. 
2. Then he shifted to how to implement tree and graph using OOPs.
3. They asked a problem on tree and mentioned solve the problem which traverses the tree only once.
4. They got the algorithm from us, and if they were satisfied, asked us to write code on the paper.

Try solving now

Here's your problem of the day

Solving this problem will increase your chance to get selected in this company

Skill covered: Programming

How do you remove whitespace from the start of a string?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by Amazon
3084 views
0 comments
0 upvotes
company logo
SDE - 1
4 rounds | 8 problems
Interviewed by Amazon
2294 views
1 comments
0 upvotes
company logo
SDE - 1
3 rounds | 6 problems
Interviewed by Amazon
1592 views
0 comments
0 upvotes
company logo
SDE - 1
4 rounds | 8 problems
Interviewed by Amazon
8962 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Microsoft
58238 views
5 comments
0 upvotes
company logo
SDE - 1
4 rounds | 8 problems
Interviewed by Samsung
12649 views
2 comments
0 upvotes
company logo
SDE - 1
4 rounds | 8 problems
Interviewed by Microsoft
5983 views
5 comments
0 upvotes