Amazon Coding & Algorithms Interview Questions

Amazon Coding & Algorithms interview questions focus heavily on data structures, algorithmic problem solving, and clear on-the-spot implementation. What’s distinctive is the combination of speed and depth: interviewers evaluate correctness, time and space complexity, edge-case handling, and the candidate’s ability to communicate a stepwise approach under time pressure. Expect array/string manipulation, trees/graphs, hashing, dynamic programming, and occasional system- or design-lite prompts for senior roles, with behavioral ties to Amazon’s leadership principles sometimes woven into technical rounds. Typical loops begin with one or two timed phone screens followed by an onsite or virtual loop of multiple interviews that mix pure coding, design (for higher levels), and behavioral assessment; a bar-raiser may appear to ensure hiring standards. For effective interview preparation, practice timed coding problems across core topics, run mock interviews that force you to verbalize decisions, write clean, testable code, and rehearse concise STAR-style stories that highlight ownership and impact. Developing pattern recognition for problem types and routinely reviewing complexity and edge cases will make your responses faster, safer, and more persuasive.

233 Questions 1 Company08.11.2026
Showing 20 results
Role
Amazon logo
Amazon
Medium
Machine Learning Engineer Locked

Determine if all courses can be completed

This question evaluates graph-theoretic dependency modeling and cycle-detection competency, measuring the ability to represent course prerequisites as...

Coding & Algorithms
2
0
16 people solved
May 30, 2026
Amazon logo
Amazon
Medium
Software EngineerSenior+ Locked

Implement Event Filtering and Queue Routing

This question evaluates parsing and evaluation of domain-specific filter expressions, JSON traversal and type-aware comparisons, boolean logic handlin...

Coding & Algorithms
2
0
15 people solved
May 30, 2026
Amazon logo
Amazon
Medium
Software Engineer Locked

Minimize Circular Redistribution Cost

This question evaluates algorithmic problem-solving skills in array manipulation, circular data structures, load balancing, and cost optimization whil...

Coding & Algorithms
5
0
31 people solved
May 24, 2026
Amazon logo
Amazon
Hard
Software Engineer Locked

Find the Most Common Visit Pattern

This question evaluates the ability to process timestamped event logs and extract ordered length-3 visit sequences, testing skills in sorting, frequen...

Coding & Algorithms
1
0
16 people solved
May 23, 2026
Amazon logo
Amazon
Medium
Software Engineer Locked

Merge Multiple Sorted Arrays

This question evaluates a candidate's competency in array manipulation, merging techniques, and algorithmic complexity analysis, including handling ed...

Coding & Algorithms
1
0
16 people solved
May 22, 2026
Amazon logo
Amazon
Hard
Software Engineer Locked

Find a Valid Course Order

This question evaluates graph algorithm skills—specifically topological ordering, directed cycle detection, and analysis of time and space complexity....

Coding & Algorithms
0
0
5 people solved
May 12, 2026
Amazon logo
Amazon
Hard
Software Engineer Locked

Build a Searchable Sentence Index

This question evaluates a candidate's ability to design and implement in-memory text indexes and related data structures, covering inverted indexing, ...

Coding & Algorithms
0
0
10 people solved
May 11, 2026
Amazon logo
Amazon
Medium
Software EngineerIntern

Implement Cache and Rotate Matrix

Solve the following two independent coding tasks. Task 1: Implement an LRU Cache Design a data structure LRUCache that stores integer keys and integer...

Coding & Algorithms
2
0
49 people solved
Apr 20, 2026
Amazon logo
Amazon
Hard
Software Engineer Locked

Find Longest Activatable Server Streak

This question evaluates array algorithm skills, specifically recognition of sliding-window or two-pointer techniques and reasoning about time and spac...

Coding & Algorithms
3
0
36 people solved
Apr 15, 2026
Amazon logo
Amazon
Medium
Software Engineer

Solve Union-Find, Graph, and Stream Problems

Solve the following independent coding problems. 1. Merge Product Categories You are given a list of tuples (productA, productB). Each tuple means the...

Coding & Algorithms
0
0
6 people solved
Apr 9, 2026
Amazon logo
Amazon
Hard
Software Engineer Locked

Minimize time for two handlers

This question evaluates algorithmic optimization skills and stateful scheduling reasoning, focusing on task assignment trade-offs and cumulative cost ...

Coding & Algorithms
7
0
98 people solved
Apr 7, 2026
Amazon logo
Amazon
Medium
Software EngineerIntern

Implement Cache and Count Components

You are asked to solve two independent coding problems in this session, each followed by a short discussion. This mirrors a 60-minute Amazon SDE codin...

Coding & Algorithms
35
0
408 people solved
Mar 7, 2026
Amazon logo
Amazon
Medium
Software EngineerIntern

Compute Latencies and Search Grid Path

You are given two coding tasks from an internship interview. Task 1: Compute Message Latency from CSV Logs Two systems, ComputeA and ComputeB, exchang...

Coding & Algorithms
0
0
15 people solved
Mar 4, 2026
Amazon logo
Amazon
Hard
Software Engineer Locked

Maximize protected population and bitwise AND

This paired problem evaluates array manipulation and resource-allocation reasoning for maximizing covered population in a constrained-movement scenari...

Coding & Algorithms
17
0
182 people solved
Feb 12, 2026
Amazon logo
Amazon
Medium
Software Engineer

Maximize protected population with one-step guard shifts

There are n cities in a line (1-indexed). You are given: - population[1..n]: population of each city - unit: a binary string of length n, where unit[i...

Coding & Algorithms
22
0
153 people solved
Jan 27, 2026
Amazon logo
Amazon
Medium
Software Engineer

Maximize weighted subsequence pairs with wildcards

You are given a string s of length n consisting only of characters '0', '1', and '!'. Each '!' can be replaced by either '0' or '1'. For the final bin...

Coding & Algorithms
113
0
1013 people solved
Jan 27, 2026
Amazon logo
Amazon
Medium
Software Engineer Locked

Find when failures started in log stream

This question evaluates understanding of monotonic sequences and search algorithms (such as binary search), along with algorithmic reasoning about cor...

Coding & Algorithms
4
0
88 people solved
Jan 22, 2026
Amazon logo
Amazon
Hard
Software EngineerSenior+ Locked

Implement array and tree traversal tasks

This question evaluates algorithmic problem-solving and data-structure competency, specifically array-based optimization for single-trade profit and t...

Coding & Algorithms
6
0
80 people solved
Jan 22, 2026
Amazon logo
Amazon
Hard
Software EngineerIntern

Count unique Morse-code word transformations

Given an array of lowercase strings words. Each letter 'a' to 'z' has a corresponding Morse code string (standard 26-letter mapping). A word’s transfo...

Coding & Algorithms
6
0
71 people solved
Jan 15, 2026
Amazon logo
Amazon
Medium
Software EngineerIntern Locked

Find minimum total range-increment to sort

This question evaluates algorithmic problem-solving skills in array manipulation and optimization, focusing on reasoning about range-increment operati...

Coding & Algorithms
6
0
51 people solved
Jan 6, 2026

Frequently Asked Questions

How difficult are Amazon Coding & Algorithms interview questions?
Amazon Coding & Algorithms interview questions typically range from medium to hard. Early screens and online assessments tend to include medium problems that test correctness, edge-case handling, and basic optimization, while onsite coding rounds push toward harder algorithmic challenges that require solid data-structure intuition, efficient designs, and careful complexity analysis. Interviewers evaluate how you reason through tradeoffs, communicate your approach, and iterate under time pressure. Preparing realistic timed practice, learning to explain constraints and invariants clearly, and polishing test-case coverage will help you reliably perform at the company’s expected difficulty level.
What does the Amazon interview process look like and where do Coding & Algorithms questions appear?
Coding and algorithmic problems appear throughout Amazon’s technical hiring funnel: they commonly start in the online assessment or phone screen and continue as core rounds during the onsite or virtual loop. Early stages focus on single-problem implementation and correctness, while later technical interviews assess algorithmic depth, optimizations, and robustness under follow-up prompts. Parallel rounds may cover system design or behavioral evaluations, but coding rounds are central for software-engineering roles and often factor heavily in hiring decisions. Expect interviews to probe both your code and your problem-solving rationale, with interviewers asking for clarifications, complexity analysis, and test cases.
How should I structure a preparation timeline for Amazon Coding & Algorithms interviews?
Plan a structured timeline that balances fundamentals, applied practice, and mock interviews. Over eight to twelve weeks you can build a strong foundation by reviewing core data structures and algorithm patterns, then transition into daily timed problem solving and focused practice on weak areas. Regularly simulate interview conditions with timed questions and live mock interviews to practice explanation and pacing. Reserve time near the end for targeted review of past mistakes, readability and testing habits, and a couple of full-loop mock interviews. Shorter intensive timelines can work, but consistency and deliberate feedback cycles accelerate readiness most effectively.
What key subtopics should I master for Coding & Algorithms interviews at Amazon?
Prioritize mastery of arrays and strings, trees and graphs (BFS/DFS, topological order), dynamic programming patterns, hashing and two-pointer techniques, heaps and priority queues, and common greedy and binary-search approaches. Understanding complexity analysis, tradeoffs between time and space, and practical implementation details like handling nulls, overflow, and edge cases is essential. Equally important are writing clean, modular code and communicating thought processes clearly while iterating from brute-force to optimized solutions. Practicing pattern recognition and learning to adapt known templates to novel problem constraints will cover most frequent question types.
What practical tips will help me stand out, and what common pitfalls should I avoid during Amazon Coding & Algorithms interviews?
Stand out by clarifying requirements up front, proposing a brute-force idea first, and then iterating toward optimizations while explaining complexity tradeoffs. Verbally walk through representative test cases, handle edge cases explicitly, and keep code readable with clear variable names and small helper functions. Manage time by setting mini-milestones: plan, code, test, and optimize. Common pitfalls include diving into code without a plan, neglecting to test edge cases, ignoring interviewer hints, and getting stuck on micro-optimizations early. Unless an interviewer permits it, avoid using external assistants during live interviews and focus on demonstrating your independent problem-solving skills.

Explore more Amazon Coding & Algorithms interview questions

Real questions from candidate reports, grouped by role, topic and company.

By role
Other categories at Amazon
Coding & Algorithms questions at other companies
Browse all