Amazon SDE-2 Interview Questions.

Difficulty: MEDIUMCategory: InterviewExperienceFrequency: 1Asked On 2025-06-27Added By Anonymous
Source: Link

Company: Amazon
Role: SDE II
Interview Stage: Onsite
Location: USA
Year: unknown

Original Post Content:

Round 1 (LLD): WAS ASKED TO SHARE SCREEN FOR THIS ROUND.
Expectation was to write a maintainable and extendable code.
Given a base path list/return all the files which match the below conditions.
- Files with .xml extension
- Files less than 5MB
Follow Up question to include a file range in the file search

Round 2: Given a 2D grid whose spaces consist of emptiness, radio towers, and mountains, determine which radio towers are able to communicate with one another.

Each radio tower's signal travels in 4 directions from the tower (UP, DOWN, LEFT, RIGHT), and the signal will travel indefinitely until it either hits a mountain, or hits another radio tower.

Expected input:
int[][] grid, where each space is either:

  • 0: Empty space
  • 1: Radio tower
  • 2: Mountain

Expected output: Some representation showing which towers can talk to which others (maybe a Map<Coordinate, List<Coordinate>> to map each tower to the towers it can see (adjacency list), but we can be flexible on the output as long as it's understandable)

Follow-up Question: Towers are given an intensity need to traverse up to the intensity only and consider overlap of signal from another tower as a valid connection.

Round 3:

  • Given a tree, Can you print the nodes in a vertical order. Imagine that the nodes are also supposed to be parsed left to right.
                2
             *     *
           3         4
        *   *     *    *
      5     6     8      7
    *   *
   9     1

output:
9, 5, 3, 1, 2, 6, 8, 4, 7

Round 4: Design a distributed ticket booking system for a movie theater chain with 500 locations across the country. The system needs to handle concurrent bookings.
Interviewer was more interested in API design and DB schema than the High Level SD

Comments