Upload Button Icon Add office photos
Engaged Employer

i

This company page is being actively managed by Amazon Team. If you also belong to the team, you can get access from here

Amazon Verified Tick

Compare button icon Compare button icon Compare
4.1

based on 24.2k Reviews

Filter interviews by

Amazon SDE-2 Interview Questions, Process, and Tips for Freshers

Updated 16 Sep 2021

Top Amazon SDE-2 Interview Questions and Answers for Freshers

  • Q1. Ways To Make Coin Change You are given an infinite supply of coins of each of denominations D = {D0, D1, D2, D3, ...... Dn-1}. You need to figure out the total number of ...read more
  • Q2. Median in a stream Given that integers are read from a data stream. Your task is to find the median of the elements read so far. Median is the middle value in an ordered ...read more
  • Q3. Shopping Options You are given the list of costs of pants in an array “pants”, shirts in an array “shirts”, shoes in an array “shoes”, and skirts in an array “skirts”. Yo ...read more
View all 16 questions

Amazon SDE-2 Interview Experiences for Freshers

3 interviews found

SDE-2 Interview Questions & Answers

user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Apr 2021.

Round 1 - Telephonic Call 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Easy

Started with brief intro(5 mins) about interviewer.
Problem solving question, question was already there in the codelink shared by the interviewer. He explained the problem again with sample testcase. 
The Interviewer was friendly.

  • Q1. Course Schedule II

    You have been given ‘N’ courses and some courses may have prerequisites. Now consider a matrix ‘PREREQUISITES’ of size 'M' x 2 which represents that you must complete course '...

  • Ans. Breadth-First Search

    Our current algorithm is based on the idea of the BFS approach. We first process all the courses with 0 in-degree implying no prerequisite courses required. If we remove all these courses from the graph, along with their outgoing edges, we can find out the courses/nodes that should be processed next. These would again be the nodes with 0 in-degree. We can continuously do this until all the courses h...

  • Answered by CodingNinjas
  • Q2. System Design

    System design a live video broadcast platform.

Round 2 - Video Call 

(2 Questions)

Round duration - 90 minutes
Round difficulty - Medium

There were 2 interviewers(India HM and Seattle HM), India HM was just shadowing and didn't ask any questions. Started with intro, he asked in detail about what I do at current company(10 mins). Again, jumped into LP's(25 mins).

  • Q1. Distance between two nodes of a Tree

    Given a binary tree and the value of two nodes, find the distance between the given two nodes of the Binary Tree.

    Distance between two nodes is defined as the minimum...

  • Ans. Naive Approach

    In any rooted tree, the distance between two nodes 'U' and 'V' can be found by finding the lowest common ancestor (LCA), ‘x’ of two nodes. The lowest common ancestor (LCA) between nodes 'U' and 'V' is defined as the lowest node in the tree that has both 'U' and 'V' as descendants, where we define each node to be a descendant of itself (so if 'U' has a direct connection from 'V', 'V' is the lowest common a...

  • Answered by CodingNinjas
  • Q2. Median in a stream

    Given that integers are read from a data stream. Your task is to find the median of the elements read so far.

    Median is the middle value in an ordered integer list. If the size of the ...

  • Ans. Brute force approach

    Store the incoming data elements in a vector. Sort the vector everytime you need to output the median.

    Algorithm:

    1. Store the incoming elements of the data stream in a vector.
    2. Step by step insert one element and sort the vector as soon as any element is added in the vector.
    3. If the size of the vector is odd, print the middle element of the sorted vector.
      If the size of the vector is even, return the mean of...
  • Answered by CodingNinjas
Round 3 - Telephonic Call 

(1 Question)

Round duration - 60 minutes
Round difficulty - Medium

There was only 1 interviewer in this round and We had no video sharing in this round so it was becoming difficult to understand each other.

  • Q1. Object Oriented Design Question

    Started with brief intro about both(5 mins), then he jumped into LP's(25 mins). This was very difficult since there was no video and he was grilling me real hard on this, so...

Interview Preparation Tips

Professional and academic backgroundI applied for the job as SDE - 2 in SeattleEligibility criteriaNAAmazon interview preparation:Topics to prepare for the interview - Data Structures - Trie, HashMap, Sets, Priority Queue, Stack, Advanced Topics like Fenwick Tree, Segment Trees, Game Theory, Dynamic Programming, Union Find,Graph Algorithms, BitmaskingTime required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Bookmark the GFG Amazon Archives. It helped me a lot during my preparations. Reading other’s interview experiences is one of the best ways to get yourselves ready for the next job interview. Practice daily atleast 5 questions.
Tip 2 : Most commonly asked topics in Amazon Interviews ( as per the mail I received from my recruiter ) :
BFS/DFS/Flood fill, Binary Search, Tree traversals, Hash tables, Linked list, stacks, queues, two pointers/sliding window
Binary heaps, Ad hoc/string manipulations.
Tip 3 : Highly recommended sites for practicing questions ( usually practice medium and hard level questions) :
Leetcode (highly encouraged)
Geeksforgeeks (highly encouraged)
CodeZen( highly encouraged)
Codeforces
Tip 4 : This is a great bigocheatsheet that could be of great help https://www.bigocheatsheet.com/

Application resume tips for other job seekers

Tip 1 : Mention past working experience in detail as how you were important to your previous company.
Tip 2 : Try to keep your resume to 1 page if work experience < 5 years
Tip 3 : Update your resume according to role you are applying for and never put false things on resume.

Final outcome of the interviewRejected

Skills evaluated in this interview

SDE-2 Interview Questions & Answers

user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Mar 2021.

Round 1 - Coding Test 

(2 Questions)

Round duration - 45 minutes
Round difficulty - Medium

This round was scheduled in the evening hours and all the participants were required to fill a form which was shared 15 minutes prior to the start of the online coding round. This form was filled out probably for the security reasons and to ensure that no one disinterested participant gives the test.

  • Q1. Ways To Make Coin Change

    You are given an infinite supply of coins of each of denominations D = {D0, D1, D2, D3, ...... Dn-1}. You need to figure out the total number of ways W, in which you can make a cha...

  • Ans. Recursion

     

    1. The idea is to use recursion.
    2. For a particular coin, we have two options either include it or exclude it.
    3. If we include that coin, then calculate the remaining number that we have to generate so recur for that remaining number.
    4. If we exclude that coin, then recur for the same amount that we have to make.
    5. Our final answer would be the total number of ways either by including or excluding.
    6. There will be two edg...
  • Answered by CodingNinjas
  • Q2. Validate BST

    You have been given a binary tree of integers with N number of nodes. Your task is to check if that input tree is a BST (Binary Search Tree) or not.

    A binary search tree (BST) is a binary tr...

  • Ans. BST property

    The approach is based on the fact that the value of each node in a BST is greater than the value of all the nodes in the left subtree and smaller than the value of all the nodes in the right subtree.

     

    Here is the complete algorithm-

    • For each node, we store the minimum and maximum value allowed for that node. Initially, for the root node, the minimum value would be -10^9 and the maximum value should be 10...
  • Answered by CodingNinjas
Round 2 - Telephonic Call 

(1 Question)

Round duration - 60 minutes
Round difficulty - Hard

This round was on call where I was just supposed to answer the tech questions that were asked. It started with a brief interview with one another and then moved to questions on DBMS, operating systems, computer networks and all. Almost 20-25 questions were asked and I probably answered 90% of them correctly.

  • Q1. Reverse Linked List
    Input Format :
    The first line of input contains a single integ...
  • Ans. Recursive Approach

    One way is to use recursion to reverse the list. Divide the linked list in two halves, the first node and the rest of the list. Reverse the second half using recursion and append the first half, that is the first node at the end of the reversed linked list. Return the head of the reversed linked list.

     

    Algorithm

     

    • If the list contains only one node, return the head of the list.
    • Else, divide the ...
  • Answered by CodingNinjas
Round 3 - HR 

(1 Question)

Round duration - 30 minutes
Round difficulty - Hard

There was only one interviewer for this round. He continuously interacted with me and was giving me some good situational problems that were not very easy to answer. Basically those were open-minded questions which can be answered oth ways and that's why I found it quiet hard as per my nature but at the end things went well for me.

  • Q1. Basic Puzzles

    A noticeable aspect in this puzzles is the fact that there’s a circular misplacement, which implies if apple is wrongly labelled as Apple, Apple can’t be labelled as Orange, i.e., it has to be...

  • Ans. 

    Note: basically it's better if you have seen some puzzles before any HR round since they will give you an idea of what kind of problem you may encounter and then you can ace any difficult to difficult HR interview.

  • Answered by CodingNinjas

Interview Preparation Tips

Professional and academic backgroundI completed Mechanical Engineering from Malaviya National Institute of Technology Jaipur. I applied for the job as SDE - 2 in HyderabadEligibility criteriaabove 7 cgpa, no backlogsAmazon interview preparation:Topics to prepare for the interview - Data Structures, hashmap, linked list, Pointers, OOPS, System Design, Algorithms, Dynamic Programming, array, 2-pointer problemsTime required to prepare for the interview - 8 monthsInterview preparation tips for other job seekers

Tip 1 : practice on gfg and coding ninjas
Tip 2 : compete on codechef and codeforces
Tip 3 : learn DSA and practice regularly

Application resume tips for other job seekers

Tip 1 : put your entire valuable experience in brief
Tip 2 : put the handle of you competitive coding profiles
Tip 3 : try to put those things that really attracts the recruiter, will be better if your past experiences relates to the company

Final outcome of the interviewSelected

Skills evaluated in this interview

SDE-2 Interview Questions Asked at Other Companies for Fresher

asked in Walmart
Q1. Maximum Frequency NumberNinja is given an array of integers that ... read more
asked in Amazon
Q2. Ways To Make Coin ChangeYou are given an infinite supply of coins ... read more
asked in Meesho
Q3. Remove Consecutive Duplicates From String You are given a string ... read more
Q4. Sum of even & oddNinja got a test problem in which he was giv ... read more
asked in Walmart
Q5. PuzzleYou are trying to cook an egg for exactly fifteen minutes, ... read more

SDE-2 Interview Questions & Answers

user image CodingNinjas

posted on 16 Sep 2021

I was interviewed in Oct 2020.

Round 1 - Coding Test 

(2 Questions)

Round duration - 90 minutes
Round difficulty - Easy

I got a call from an Amazon recruiter regarding the schedule of the test . She sent me the coding test link which I had to complete within a week. we can attempt the online test anytime, when we have time for a period of 90 minutes at a stretch.Once I completed the test, I got a call to schedule the interviews in two weeks.

  • Q1. Shopping Options

    You are given the list of costs of pants in an array “pants”, shirts in an array “shirts”, shoes in an array “shoes”, and skirts in an array “skirts”. You are also given a budget amount ‘X...

  • Ans. Brute Force

    We can check all possible combinations to buy items. That can be done by maintaining a variable “answer” and iterating over all four lists in a nested way such that each pant, shirt, shoe, and skirt pair can get selected and find the sum of that pair. If sum is less than or equal to budget then increment “answer” by one. Return the “answer”.


    Algorithm:

     

    • Create an integer “answer” equal to 0.
    • First iterate ...

  • Answered by CodingNinjas
  • Q2. Max Submatrix

    Ninja has been given a matrix ‘MAT’ of integers having size ‘N’ x ‘M’ i.e. N rows and M columns. Ninja has to find the maximum sum submatrix in it. In other words, he has to find the maximum ...

  • Ans. Brute Force

    The brute force approach is we check for every possible submatrix in the given ‘MAT’.

    • 4 nested loops are required to select every submatrix of the matrix.
    • 2 nested loops are required to take the sum of all the elements of the submatrix.

    Here is the algorithm :

    1. We declare a variable ‘MAX_SUM’ in which we store the maximum sum over all submatrices in the matrix.
    2. We run a loop for ‘i’ = 0 to ‘N’:
      • We run a loop for ‘j...
  • Answered by CodingNinjas
Round 2 - Video Call 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Medium

Virtual interview occured in amazon chime.The interviewer gave his introduction, asked me a bit on the kind of projects I’ve worked on. Then he started with a data structure problem.

  • Q1. Clone a binary tree with random pointers.

    You are given a binary tree. Apart from the left and right child pointers, each node in the given binary tree points to a random node in the given binary tree. You...

  • Ans. HashMap based approach

    The idea is to use a HashMap to map the tree nodes to each clone node. We will traverse the binary tree and create a clone tree with the random pointer equal to NULL and map each node of the given tree to its clone node. Now we will again iterate through the tree and add the random pointer of each node by looking up the HashMap. 

     

    The steps are as follows:

    1. Let’s define a HashMap to map eac...
  • Answered by CodingNinjas
  • Q2. Ninja Port

    Ninja is stuck in a city with ‘N’ colonies, and each colony contains ‘K’ houses. Ninja is currently at the house number “sourceHouse” present in the colony with colony number “sourceColony”. He ...

  • Ans. Breadth First Search

    We can initially create a graph with 2 nodes from each colony i.e. the first and last house of each colony would be included in the graph. We also create an edge from the node representing the last node of each colony to the node representing the first node of the next colony, and vice versa.
     

    Now, we add into the graph each house that has an outgoing or incoming secret path. We also make edges ...

  • Answered by CodingNinjas
Round 3 - Video Call 

(1 Question)

Round duration - 75 Minutes
Round difficulty - Easy

This was taken by an engineering manager who asked me regarding my projects for around 10-15 mins and then we moved to a system design problem. He asked me to design Slack messenger.
I started by listing the functional and non-functional requirements(on which he questioned me a bit), then I moved to draw the high-level architecture. The components which I drew were the clients, gateway service(LB + authentication, etc), Messaging Service, User Service, Web Socket Manager service, Fan Out service(I added this for the group messages thing, but he didn’t interrogate much on that).

He asked me what would be the schema of my messages table and the scenarios in which the recipient user is online/offline.Also asked about the partitioning key and primary key of the 2-3 tables which I had made

  • Q1. Technical Questions

    This was taken by an SDE III guy, who again asked me about my projects for like 10 mins and then moved on to a low level design question.He asked me to design the HackerRank platform.
    Aga...

Round 4 - Video Call 

(2 Questions)

Round duration - 60 minutes
Round difficulty - Hard

BarRaiser Round

This was again taken by an engineering manager who discussed my projects in depth for around 20-25 mins. In the remaining time he asked me 2 dsa questions. (Yes I too was surprised that he didn’t ask anything regarding design).

In almost all the rounds, I was asked questions related to Amazon Leadership principles, so do make sure you go through those before sitting for the interview process. You can refer to this link(https://www.codingninjas.com/codestudio/problem-lists/top-amazon-coding-interview-questions) for practicing the same, I found it useful. 
In the design rounds, interviewer doesn’t expect the most ideal answer from you and unless your choice of technology is outrageously wrong, he won’t pinpoint that.

  • Q1. Group Anagrams Together

    You have been given an array/list of strings 'STR_LIST'. You are supposed to return the strings as groups of anagrams such that strings belonging to a particular group are a...

  • Ans. Sorting based Approach

    The idea behind this approach is that two or more than two strings are anagrams if and only if their sorted strings are equal. So we will use a HashMap, let’s say “anagramGroup”, where each key is a sorted string, and the key will be mapping to the list of indices from the given list of strings that form a group of anagrams. This means that if we sort the strings at those indices, we will get the ...

  • Answered by CodingNinjas
  • Q2. Add Linked Lists

    Given two numbers represented by linked lists. Your task is find the sum list and return the head of the sum list.

    The sum list is a linked list representation of addition of two numbers...

  • Ans. Recursive approach

    One way is to recursively add the two linked lists. Keep the nodes in the recursion stack and add the last nodes first and then second last and so on. Initially, find the size of both the linked lists. If both the linked lists are of the same size, add them using recursion. Else if their sizes differ, move the head pointer of the larger linked list forward K times, where K is the difference between th...

  • Answered by CodingNinjas

Interview Preparation Tips

Professional and academic backgroundI completed Computer Science Engineering from Sathyabama Institute Of Science And Technology. I applied for the job as SDE - 2 in HyderabadEligibility criteriaNo CGPA criteriaAmazon interview preparation:Topics to prepare for the interview - Data Structures and Algorithms, OOPS concepts, cpp, operating systems, dbmsTime required to prepare for the interview - 3 monthsInterview preparation tips for other job seekers

Tip 1 : Expect questions related to Amazon Leadership principles in all rounds, so go through those thoroughly before sitting for the interview process.
Tip 2 : In the design rounds, interviewer doesn’t expect the most ideal answer from you and unless your choice of technology is outrageously wrong, he won’t pinpoint that.
Tip 3 : Data Structures questions are a must in all rounds, so try to master them thoroughly

Application resume tips for other job seekers

Tip 1 : Make sure you know everything you mention in your resume
Tip 2 : Have some hands on with hackathons and contests ,which brings an added value to your resume

Final outcome of the interviewRejected

Skills evaluated in this interview

Interview questions from similar companies

Sde1 Interview Questions & Answers

Uber user image Anonymous

posted on 12 Jun 2023

Interview experience
1
Bad
Difficulty level
Easy
Process Duration
Less than 2 weeks
Result
Selected Selected

I applied via Company Website and was interviewed in May 2023. There were 3 interview rounds.

Round 1 - Resume Shortlist 
Pro Tip by AmbitionBox:
Keep your resume crisp and to the point. A recruiter looks at your resume for an average of 6 seconds, make sure to leave the best impression.
View all tips
Round 2 - Coding Test 

Very Easy questions just do it

Round 3 - One-on-one 

(4 Questions)

  • Q1. What is your introduction
  • Q2. Why SDE 1 only not SDE 2
  • Ans. 

    SDE 1 is an entry-level position where candidates gain foundational skills before advancing to SDE 2.

    • SDE 1 focuses on learning and building foundational skills in software development.

    • SDE 2 requires more experience and expertise in software development.

    • Advancing from SDE 1 to SDE 2 is a common career progression in tech companies.

    • SDE 1 roles often involve working on smaller projects or components of larger projects.

    • SDE...

  • Answered by AI
  • Q3. If bully happens will you bully someone
  • Ans. 

    No, I believe in standing up against bullying and supporting those who are being bullied.

    • I do not support bullying in any form and believe in treating others with respect and kindness.

    • I would try to intervene and help the person being bullied, either by talking to the bully or seeking help from a teacher or supervisor.

    • I believe in creating a positive and inclusive environment where everyone feels safe and respected.

  • Answered by AI
  • Q4. If taken leave can you work 7 days a week

Interview Preparation Tips

Interview preparation tips for other job seekers - Keep yourself you only and you will get a wholesome of 60 LPA
Interview experience
5
Excellent
Difficulty level
Moderate
Process Duration
Less than 2 weeks
Result
Selected Selected

I applied via LinkedIn and was interviewed before Jul 2023. There were 2 interview rounds.

Round 1 - Aptitude Test 

Moderate questions can be found on gfg

Round 2 - Coding Test 

4 graph question and one DP

Interview Preparation Tips

Interview preparation tips for other job seekers - Study hard easy

Amazon Interview FAQs

How many rounds are there in Amazon SDE-2 interview for freshers?
Amazon interview process for freshers usually has 2-3 rounds. The most common rounds in the Amazon interview process for freshers are Coding Test, Technical and One-on-one Round.
What are the top questions asked in Amazon SDE-2 interview for freshers?

Some of the top questions asked at the Amazon SDE-2 interview for freshers -

  1. There is a 12 km road and a contractor who is in-charge of repairing it. Contra...read more
  2. Given a string you need to print all possible strings that can be made by placi...read more
  3. Design data structure that supports insert(), remove(), find-max(), delete-max(...read more

Tell us how to improve this page.

SDE-2 Interview Questions from Similar Companies

Flipkart SDE-2 Interview Questions
4.0
 • 5 Interviews
Uber SDE-2 Interview Questions
4.2
 • 2 Interviews
Paytm SDE-2 Interview Questions
3.3
 • 1 Interview
OLX SDE-2 Interview Questions
3.8
 • 1 Interview
View all
Amazon SDE-2 Salary
based on 307 salaries
₹24.3 L/yr - ₹80 L/yr
59% more than the average SDE-2 Salary in India
View more details

Amazon SDE-2 Reviews and Ratings

based on 18 reviews

2.8/5

Rating in categories

3.0

Skill development

2.2

Work-Life balance

3.3

Salary & Benefits

2.3

Job Security

2.4

Company culture

2.8

Promotions/Appraisal

2.5

Work Satisfaction

Explore 18 Reviews and Ratings
Customer Service Associate
4.1k salaries
unlock blur

₹0.6 L/yr - ₹6 L/yr

Transaction Risk Investigator
3.1k salaries
unlock blur

₹2.3 L/yr - ₹6.5 L/yr

Associate
2.8k salaries
unlock blur

₹0.8 L/yr - ₹6.9 L/yr

Senior Associate
2.4k salaries
unlock blur

₹2 L/yr - ₹10.1 L/yr

Software Development Engineer
2k salaries
unlock blur

₹16.3 L/yr - ₹33.7 L/yr

Explore more salaries
Compare Amazon with

Flipkart

4.0
Compare

TCS

3.7
Compare

Google

4.4
Compare

Netflix

4.5
Compare

Calculate your in-hand salary

Confused about how your in-hand salary is calculated? Enter your annual salary (CTC) and get your in-hand salary
Did you find this page helpful?
Yes No
write
Share an Interview