i
Amazon
Proud winner of ABECA 2025 - AmbitionBox Employee Choice Awards
Filter interviews by
Construct a binary tree using given preorder and postorder traversals.
Preorder traversal: Root -> Left -> Right.
Postorder traversal: Left -> Right -> Root.
The first element of preorder is the root of the tree.
The last element of postorder is also the root of the tree.
To build the tree, recursively find left and right subtrees.
Example: Preorder: [A, B, D, E, C] and Postorder: [D, E, B, C, A] forms a tre...
Find two numbers in an array that add up to a specific target sum.
Use a hash map to store numbers and their indices for quick lookup.
Iterate through the array, calculating the complement for each number.
Example: For nums = [2, 7, 11, 15] and target = 9, return indices [0, 1].
Time complexity is O(n) due to single pass through the array.
I handle pressure by staying organized, prioritizing tasks, and taking breaks when needed.
I prioritize tasks based on deadlines and importance
I break down large tasks into smaller, manageable steps
I communicate with team members or supervisors if feeling overwhelmed
I practice mindfulness techniques like deep breathing or meditation to stay calm
Calculate the amount of water that can be trapped between elevation bars after rainfall.
Use two pointers to traverse the height array from both ends.
Maintain left and right max heights to calculate trapped water.
Example: For heights [0,1,0,2,1,0,1,3,2,1,2,1], the trapped water is 6.
What people are saying about Amazon
Combine ropes to minimize cost by always combining the two shortest ropes
Sort the ropes in ascending order
Combine the two shortest ropes at each step
Update the cost and add the new combined rope back to the list
Repeat until only one rope is left
A linked list is a data structure consisting of nodes where each node points to the next node in the sequence.
Create a Node class with data and next pointer
Initialize a head pointer to null
Add nodes by updating next pointers
To find a loop in a linked list, use Floyd's Tortoise and Hare algorithm.
Use two pointers, slow and fast, to traverse the linked list.
If there is a loop, the two pointers will eventually meet at the same node.
To find the start of the loop, reset one pointer to the head and move both pointers at the same pace.
BigO of OA refers to the time complexity analysis of the algorithm OA.
BigO notation is used to describe the worst-case time complexity of an algorithm.
It provides an upper bound on the growth rate of the algorithm's time complexity as the input size increases.
For example, if an algorithm has a time complexity of O(n^2), it means that the algorithm's running time grows quadratically with the input size.
An LRU cache efficiently stores a limited number of items, evicting the least recently used when full.
LRU stands for Least Recently Used, a cache eviction policy.
It maintains a fixed size and removes the least recently accessed item when full.
Commonly implemented using a combination of a hash map and a doubly linked list.
Example: If a cache size is 2 and items 1, 2, 3 are accessed, 1 and 2 are stored, then 3 evict...
Spring is immutable
Spring framework is immutable
Once a Spring bean is created, its state cannot be changed
Any modifications to a Spring bean result in a new instance being created
The longest continuous patch of a road being repaired by a contractor is determined.
Iterate through the updates and keep track of the start and end points of each patch
Calculate the length of each patch and update the longest patch if necessary
Return the start and end points of the longest patch
Implementing a Least Recently Used (LRU) Cache using a combination of a doubly linked list and a hash map for O(1) access.
Use a hash map to store key-value pairs for O(1) access.
Maintain a doubly linked list to track the order of usage.
When accessing an item, move it to the front of the list.
When adding a new item, check if the cache is full; if so, remove the least recently used item from the back of the list.
Example:...
The program counts the number of tree structures that can be made using n nodes.
Use dynamic programming to solve the problem efficiently
Break down the problem into subproblems and store their solutions in an array
Iterate through the array to calculate the number of tree structures
The time complexity of the program is O(n^2)
Arrange nuts and bolts so that every nut fits perfectly with the bolt in the same position.
Sort both arrays in the same order using a comparison function
Use a binary search to find the matching bolt for each nut
Repeat until all nuts are matched with bolts
Measure the time from typing a URL to page load using network requests and timestamps.
Use browser developer tools to monitor network requests and timestamps.
Implement a JavaScript function to capture the time when the URL is entered.
Send a dummy request after the page load to measure response time.
Utilize performance APIs like 'performance.now()' for precise timing.
Log the time taken for DNS resolution, TCP connection,...
I applied via Referral and was interviewed in Dec 2024. There were 2 interview rounds.
OA consisted of two DSA questions.
I applied via LinkedIn and was interviewed in Nov 2024. There were 3 interview rounds.
Simple Normal DSA Question
Focus on DSA and optimization
Project Discussion and some Date structure questions
Good DSA Questions
Recursion, Graph and Tree
I applied via Company Website and was interviewed in Aug 2024. There were 2 interview rounds.
There are two straightforward data structure and algorithm questions, while the others primarily consist of multiple-choice questions, mostly focusing on nodes and Python.
In the telephonic round, they primarily assess your problem-solving skills. The interviewer asked me a binary search question, which I was able to solve, but it took me a considerable amount of time to arrive at the solution. This was likely the main reason for my rejection.
I applied via Naukri.com and was interviewed in Sep 2024. There was 1 interview round.
Find the order of excecution in sql
I applied via LinkedIn and was interviewed in Nov 2024. There was 1 interview round.
It was a one hour DS Algo Round based on recursion and DP. I managed to get to the logic for the problem but couldn't execute compltely due to time constraints
I applied via Naukri.com and was interviewed in May 2024. There were 2 interview rounds.
HACKER RANK TEST WITH MEDIUM LEVEL QUESTIONS
To find a loop in a linked list, use Floyd's Tortoise and Hare algorithm.
Use two pointers, slow and fast, to traverse the linked list.
If there is a loop, the two pointers will eventually meet at the same node.
To find the start of the loop, reset one pointer to the head and move both pointers at the same pace.
I applied via Company Website and was interviewed in Jul 2024. There were 5 interview rounds.
SLiding window problem
Tree problem variation
DP Problems same questions but with different cases
I worked at a tech startup where I developed web applications and implemented new features.
Led a team of developers to successfully launch a new mobile app
Implemented a new payment gateway system to improve user experience
Collaborated with product managers to prioritize and deliver features on time
Some of the top questions asked at the Amazon SDE interview -
The duration of Amazon SDE interview process can vary, but typically it takes about less than 2 weeks to complete.
based on 37 interview experiences
Difficulty level
Duration
based on 26 reviews
Rating in categories
Customer Service Associate
4k
salaries
| ₹1.8 L/yr - ₹5 L/yr |
Transaction Risk Investigator
3.1k
salaries
| ₹2.9 L/yr - ₹6.5 L/yr |
Associate
3.1k
salaries
| ₹2 L/yr - ₹5.5 L/yr |
Senior Associate
2.6k
salaries
| ₹4 L/yr - ₹9 L/yr |
Software Developer
2.5k
salaries
| ₹23.5 L/yr - ₹43.8 L/yr |
Flipkart
TCS
Netflix