Coding & Algorithms Interview Questions

Practice 3,469 real Coding & Algorithms interview questions for 2026. Covers companies like Meta, Amazon, Google, Uber, and Microsoft. Real questions from actual interviews with detailed solutions — ideal for focused interview preparation. Coding & Algorithms interview questions are the single most common technical gate for software engineering roles and are used to evaluate problem framing, algorithm selection, complexity trade-offs, correctness, edge-case reasoning, and clear communication under time pressure. Expect this category to appear in early technical screens and repeatedly across onsite loops at companies that weight it heavily (notably Meta, Google, and Amazon). Interviews will test arrays and strings, trees and graphs, dynamic programming, hashing and two‑pointer techniques, and the candidate’s ability to test and optimize code in a shared editor. Prepare with timed mock interviews, practice in the same editor you’ll use live, and build a progressive schedule that moves from fundamentals to medium/hard problems; typical candidates invest several weeks to a few months of focused practice depending on seniority and target company.

3.5k Questions 368 Companies08.11.2026
Showing 20 results
Role
Waymo logo
Waymo
Medium
Site Reliability Engineer

Determine Complete Interval Coverage

You need to process a stream of real-valued points on a one-dimensional target segment from 0 to 50. Each time a point x arrives, it contaminates the ...

Coding & Algorithms
8
0
74 people solved
Feb 7, 2026
Microsoft logo
Microsoft
Medium
Software Engineer

Fill rooms with nearest-gate distance

You are given an m×n grid representing a building floor plan: - -1 = wall/blocked cell - 0 = gate - A large positive number (e.g., INF = 2^31-1) = emp...

Coding & Algorithms
6
0
58 people solved
Feb 7, 2026
Meta logo
Meta
Medium
Software Engineer Locked

Solve maze reachability and two follow-ups

This set of tasks evaluates graph and state-space search with constrained movement (maze rolling ball), tree algorithms and recursion for computing di...

Coding & Algorithms
12
0
96 people solved
Feb 7, 2026
Google logo
Google
Medium
Software Engineer Locked

Detect and remove matched words in a char stream

This question evaluates understanding of online stream processing, substring matching, and the use of efficient data structures and algorithms for rea...

Coding & Algorithms
35
0
238 people solved
Feb 7, 2026
Hebbia logo
Hebbia
Medium
Software Engineer

Implement a Cache Snapshot Printer

Implement an LRU-style cache and a snapshot-printing feature. The cache stores key-value pairs and has a fixed capacity. It should support normal cach...

Coding & Algorithms
2
0
23 people solved
Feb 6, 2026
DoorDash logo
DoorDash
Hard
Software Engineer

Calculate Daily Driver Pay

You are given a one-day event log for a delivery driver. Each input record is a JSON event with fields such as order_id, event_type, timestamp, and ba...

Coding & Algorithms
6
0
76 people solved
Feb 6, 2026
Waymo logo
Waymo
Medium
Software EngineerSenior+ Locked

Can You Reach the Last Index?

This question evaluates a candidate's understanding of array traversal and reachability in sequences of jumps, along with the ability to reason about ...

Coding & Algorithms
14
0
108 people solved
Feb 6, 2026
NVIDIA logo
NVIDIA
Easy
Software Engineer

Find the nth prime number

Given an integer n (1-indexed), return the n-th prime number (e.g., n=1 -> 2, n=2 -> 3, n=3 -> 5). Design an algorithm that is efficient for moderatel...

Coding & Algorithms
5
0
104 people solved
Feb 6, 2026
Paradromics logo
Paradromics
Medium
Software Engineer

Compute ways to climb n steps

Implement a function that returns the number of distinct ways to reach the top of a staircase with n steps if you can climb either 1 or 2 steps at a t...

Coding & Algorithms
4
0
29 people solved
Feb 6, 2026
Google logo
Google
Easy
Software Engineer

Implement Batched Undo/Redo Layer

You are implementing a simplified document layer for a design tool. The layer stores properties as a map<string, string>. Implement a class that suppo...

Coding & Algorithms
7
0
57 people solved
Feb 4, 2026
SoFi logo
SoFi
Medium
Software Engineer

Find the second most frequent tag

You are given a list of strings in the following repeating order: [id1, name1, tag1, id2, name2, tag2, ...] So every 3 consecutive elements describe o...

Coding & Algorithms
14
0
113 people solved
Feb 4, 2026
Hard
Software Engineer

Implement a multi-button click detector

Implement a click detector for multiple physical buttons. You receive button state updates as a stream. Each update provides: - button_id (integer) - ...

Coding & Algorithms
6
0
54 people solved
Feb 3, 2026
Optiver logo
Optiver
Hard
Data Scientist Locked

Find missing numbers in sequences

This question evaluates sequence pattern recognition, numerical reasoning with integers and rational numbers, and the ability to infer recurrences or ...

Coding & Algorithms
14
0
275 people solved
Feb 3, 2026
Databricks logo
Databricks
Medium
Software Engineer Locked

Compute 5-minute rolling average load

This question evaluates understanding of sliding-window aggregation and efficient data-structure design for time-series event streams, focusing on com...

Coding & Algorithms
8
0
159 people solved
Feb 3, 2026
Google logo
Google
Easy
Data Scientist Locked

Build next-word predictor with O(1) lookup

This question evaluates skills in language modeling, data structures, algorithmic optimization, and probabilistic sampling, within the Coding & Algori...

Coding & Algorithms
4
1
43 people solved
Feb 2, 2026
Reevo logo
Reevo
Medium
Software Engineer

Output lexicographically largest DFS traversal

You are given a graph with n nodes labeled 1..n and m edges. Assume an undirected graph unless stated otherwise. You must output a node visitation seq...

Coding & Algorithms
2
0
24 people solved
Feb 2, 2026
Reevo logo
Reevo
Medium
Software Engineer

Count all palindromic substrings

Given a string s, count how many substrings of s are palindromes. - A substring is a contiguous block of characters. - A palindrome reads the same for...

Coding & Algorithms
4
0
30 people solved
Feb 2, 2026
Reevo logo
Reevo
Medium
Software Engineer

Maximize weighted sum with disjoint adjacent swaps

You are given an integer array arr of length n (0-indexed). Define the weighted sum as: S = Σ_{i=0..n-1} arr[i] * (i + 1). You may perform any number ...

Coding & Algorithms
3
0
34 people solved
Feb 2, 2026
Notion logo
Notion
Easy
Software Engineer

Implement Table Aggregation

You are given a table represented as a list of rows. Each row contains: - key: a string identifying a group - value: an integer Write a function that ...

Coding & Algorithms
34
0
280 people solved
Feb 1, 2026
Bytedance logo
Bytedance
Easy
Software Engineer

Find Missing Ranges with Bounds

Given a sorted array of distinct integers nums and two integers lower and upper that define an inclusive interval [lower, upper], return all maximal r...

Coding & Algorithms
4
0
36 people solved
Feb 1, 2026

Frequently Asked Questions

How difficult are Coding & Algorithms interview questions?
Difficulty spans a wide range: from quick easy warm-ups to multi-stage hard problems that require advanced data structures or algorithmic proofs. Most companies place a majority of live coding rounds at the medium level, with occasional hard questions used to distinguish senior candidates. Interviewers evaluate problem framing, algorithm choice, time/space complexity, clean implementation, and thoughtful testing under time pressure. Expect more conceptual depth at Google, more consistent medium-to-hard screens at Meta, and Amazon to mix coding with leadership signals. Leveling depends on role and seniority: entry-level focuses on fundamentals; senior roles emphasize design, optimizations, and tradeoffs.
Where does Coding & Algorithms appear in a typical interview loop, and which companies weight it most heavily?
Coding & Algorithms is usually the first technical hurdle: it appears in phone/online screens, followed by one or more onsite or virtual coding rounds during the loop. Typical sequences are a technical screen, two to three in-loop coding sessions, then system design or behavioral rounds. Companies that weight this category heavily include Google, Meta, and Amazon, where coding performance often determines whether you progress. Candidates commonly concentrate practice for weeks or months beforehand; most targeting large tech firms prepare intensively for 6–12 weeks, while some spend 3–6 months for deeper mastery or level changes.
How long should I prepare and how should I structure that preparation?
Plan focused, progressive practice over a realistic timeline. A practical structure is an 8–12 week block: weeks 1–2 solidify fundamentals and language fluency; weeks 3–6 target core patterns (arrays, trees, graphs, DP) with timed problem sessions and pattern tagging; weeks 7–9 emphasize mock interviews, end-to-end problem solving, and optimization tradeoffs; final weeks simulate real loops with full-length sessions and targeted weak-point drills. Candidates with less experience may extend to 12–16 weeks. Regularly review mistakes, practice communicating solutions aloud, and include at least one weekly mock interview with peer or coach feedback.
What key subtopics and patterns should I master for Coding & Algorithms interviews?
Master a consistent set of patterns and their variations: arrays and strings (two pointers, sliding window), hash maps and frequency counts, sorting and binary search, recursion and backtracking, dynamic programming, trees and traversals, graphs (BFS/DFS, shortest paths, union-find), heaps and priority queues, and greedy algorithms. Also practice complexity analysis, space-time tradeoffs, and writing bug-resistant code with tests. For higher levels, focus on amortized analysis, advanced graph algorithms, segment trees or Fenwick trees, and system-aware optimizations. Interviewers value reusable problem templates and the ability to generalize patterns to new prompts.
What are standout tips and common pitfalls to avoid in Coding & Algorithms interviews?
Start by clarifying requirements and constraints, then outline your approach before coding. Write a correct, readable baseline solution first, then iterate to improve complexity while narrating tradeoffs. Test with simple and edge cases, and handle nulls, off-by-one, and empty inputs explicitly. Communicate continuously; silence looks like confusion. Avoid premature optimization, overcomplicating solutions, or ignoring interviewer hints. Time management matters: if stuck, discuss alternate approaches and code a partial solution. Finally, practice mock interviews to reduce anxiety and build the habit of clear, structured explanations under pressure.

Explore more Coding & Algorithms interview questions

Jump straight to Coding & Algorithms questions at a specific company or for a specific role.

By company
By role