amazon logo
Amazon· SDE-2

Amazon last 6 months DSA question compilation

Result
Rejected
Posted
18 Dec 2025
513 reads

Summary

Applied for SDE-2 role at Amazon. Focused on DSA preparation but faced challenges in LLD round due to lack of backend system design knowledge. Overall, the interview process was intense and provided a comprehensive overview of the company's technical rigor.

How it went

I recently gave an SDE-2 interview at Amazon, and this is the list of questions I found on LeetCode Discuss that I used for preparation. Unfortunately, I was rejected in the LLD round because the interviewer focused on backend LLD, while I had prepared only for mobile development LLD. I hope this will be useful for everyone who has an interview scheduled.

Questions asked (16)

  1. 01

    Bus Routes

    Data Structures & Algorithms · Hard

    Given a list of bus routes where each route has multiple stops, find the minimum number of buses to take to get from a source to a destination stop.

    Open the problem
  2. 02

    Course Schedule II

    Data Structures & Algorithms · Medium

    Given a list of courses and their prerequisites, find an order to take the courses such that all prerequisites are satisfied.

    Open the problem
  3. 03

    Detect Cycles In 2D Grid

    Data Structures & Algorithms · Hard

    Determine if there is a cycle in a 2D grid where each cell represents a node connected to its adjacent cells.

    Open the problem
  4. 04

    Evaluate Division

    Data Structures & Algorithms · Medium

    Given equations in the form of a/b = k, determine the value of a given query like a/c.

    Open the problem
  5. 05

    Find Eventual Safe States

    Data Structures & Algorithms · Hard

    Determine which nodes in a directed graph are safe states, meaning there is no cycle and no path leads to a cycle.

    Open the problem
  6. 06

    Keys And Rooms

    Data Structures & Algorithms · Medium

    Determine if all rooms in a building can be unlocked starting from room 0, given that each room contains keys to other rooms.

    Open the problem
  7. 07

    Max Consecutive Ones III

    Sliding Window · Medium

    Find the maximum number of consecutive 1s in a binary array you can get by flipping at most k 0s to 1s.

    Open the problem
  8. 08

    Minimum Operations To Reduce X To Zero

    Sliding Window · Hard

    Find the minimum number of operations to reduce a number X to zero by either subtracting a number from the array or subtracting 1 from X.

    Open the problem
  9. 09

    Magnetic Force Between Two Balls

    Binary Search · Hard

    Calculate the maximum possible minimum distance between two balls placed in a line of positions, given certain constraints on their placement.

    Open the problem
  10. 10

    Search In Rotated Sorted Array

    Binary Search · Hard

    Find the index of a target element in a sorted array that has been rotated at some pivot point.

    Open the problem
  11. 11

    Longest Valid Parentheses

    Stack · Hard

    Find the length of the longest valid parentheses substring in a given string.

    Open the problem
  12. 12

    Remove K Digits

    Stack · Medium

    Remove k digits from a number represented as a string to make the resulting number as small as possible.

    Open the problem
  13. 13

    Best Time To Buy And Sell Stock II

    Greedy · Easy

    Find the maximum profit that can be achieved by buying and selling stocks on different days, with the constraint that you can only hold one stock at a time.

    Open the problem
  14. 14

    Merge K Sorted Lists

    Linked List · Hard

    Merge k sorted linked lists into one sorted list.

    Open the problem
  15. 15

    Integer To English Words

    Math & Geometry · Hard

    Convert an integer to its English words representation.

    Open the problem
  16. 16

    Merge Intervals

    Intervals · Hard

    Merge overlapping intervals in a list of intervals.

    Open the problem

How they prepared

Prepared extensively for DSA topics, focusing on graph algorithms, system design, arrays, trees, dynamic programming, and other key areas. Used LeetCode Discuss to compile a list of problems for targeted practice.

Know someone preparing? Send it to them:WhatsAppLinkedInX

Interviewed at Amazon recently?

Write up your rounds while you still remember the questions. It helps the next person more than you would think.

Share your experience
Discussion 0

Questions for the author, or how your own interview compared.

Join the discussion

Sign in with Google to comment or ask the author a question.

No comments yet

Be the first to share your thoughts and start the discussion!