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
Meta logo
Meta
Medium
Machine Learning Engineer Locked

Debug and optimize a card-drawing strategy

This question evaluates debugging and implementation skills, combinatorial search and optimization, and the ability to design and interpret simulation...

Coding & Algorithms
21
0
156 people solved
Feb 12, 2026
Stripe logo
Stripe
Medium
Software EngineerIntern

Simulate sticky load balancer with shutdown

Problem Implement a simulator for a load balancer that routes long-lived WebSocket connections across m backend servers. You receive a sequence of tex...

Coding & Algorithms
14
0
139 people solved
Feb 12, 2026
Amazon logo
Amazon
Medium
Software EngineerNew Grad

Solve Three Algorithm Variants

You are given three independent coding problems. For each one, describe and implement an efficient solution. 1. Generate queue arrangements - You a...

Coding & Algorithms
1
0
22 people solved
Apr 10, 2026
Meta logo
Meta
Medium
Software Engineer

Implement an in-memory key-field-value DB with TTL

In-Memory DB with TTL + Scan + Backup/Restore Implement an in-memory database storing records by (key, field) -> value with optional TTL. Data model /...

Coding & Algorithms
10
0
130 people solved
Feb 11, 2026
Capital One logo
Capital One
Medium
Software Engineer

Solve powers, phases, grid pops, and swaps

Solve the following four problems: 1) Count powers of k in an array: Given an array of positive integers nums and an integer k >= 1, return how many e...

Coding & Algorithms
12
0
129 people solved
Sep 6, 2025
OpenAI logo
OpenAI
Medium
Machine Learning Engineer Locked

Simulate Grid Infection

This question evaluates skills in multi-source breadth-first search, synchronous simulation updates, boundary handling, and off-by-one correctness wit...

Coding & Algorithms
20
0
135 people solved
Mar 9, 2026
Roblox logo
Roblox
Medium
Machine Learning Engineer Locked

Level-Ordered Dependency Build Order

This question evaluates a candidate's ability to model dependency relationships as a graph and produce a valid topological build order. It tests knowl...

Coding & Algorithms
0
0
7 people solved
Jun 21, 2026
Applied logo
Applied
Medium
Software Engineer Locked

Multi-Agent Collision Simulator (Unicycle Kinematics)

This question tests practical coding ability in robotics simulation, specifically implementing unicycle kinematics and discrete-time modeling via forw...

Coding & Algorithms
0
0
5 people solved
Jun 21, 2026
Stripe logo
Stripe
Medium
Software Engineer

Implement a CSV dataset join

Implement joinDataSet(fieldName, customerFile, processorFile, skipUnmatched). You are given two datasets represented as List<String>, where: - custome...

Coding & Algorithms
9
0
94 people solved
Jan 14, 2026
Palantir logo
Palantir
Easy
Software Engineer

Find Shortest Paths in Road Network

You are reviewing code for a road-network graph. The domain objects are: `java class Location { String name; Location(String name) { this.name...

Coding & Algorithms
2
0
19 people solved
Mar 8, 2026
Adobe logo
Adobe
Medium
Machine Learning Engineer Locked

Implement K-means clustering from scratch

This question evaluates a candidate's understanding of clustering algorithms and practical implementation skills in unsupervised machine learning, inc...

Coding & Algorithms
8
0
121 people solved
Jan 13, 2026
OpenAI logo
OpenAI
Hard
Machine Learning Engineer Locked

Simulate Infection Spread on a Grid

This question evaluates the ability to implement and reason about discrete-time, grid-based simulations with multi-state cells and neighbor-dependent ...

Coding & Algorithms
7
0
80 people solved
May 11, 2026
Databricks logo
Databricks
Medium
Software Engineer

Implement a snapshotable set with iterators

Implement a SnapshotSet data structure with the following API: add(x), remove(x), contains(x), snapshot() -> sid, and iterate(sid) -> iterator over th...

Coding & Algorithms
34
0
495 people solved
Aug 11, 2025
LinkedIn logo
LinkedIn
Easy
Software EngineerSenior+ Locked

Design O(1) Randomized Multiset

This question evaluates data-structure design skills, understanding of hashing and randomization for uniform sampling, handling of duplicate elements,...

Coding & Algorithms
5
0
56 people solved
Apr 6, 2026
Antra logo
Antra
Medium
Software Engineer Locked

Longest Substring Without Repeating Characters

This question tests a software engineer's ability to apply sliding window techniques and string manipulation to optimize character uniqueness tracking...

Coding & Algorithms
0
0
6 people solved
Jun 20, 2026
Bytedance logo
Bytedance
Hard
Software Engineer Locked

Course Schedule Feasibility

This question tests graph traversal skills and the ability to detect cycles in a directed graph, a core competency in algorithm interviews. It falls u...

Coding & Algorithms
0
0
7 people solved
Jun 20, 2026
Instacart logo
Instacart
Medium
Software Engineer

Implement bus route simulation features

Bus Route Simulation – Boarding, Capacity, and Priority Passes You are given a partially implemented codebase for simulating bus routes in a city. Bus...

Coding & Algorithms
61
0
436 people solved
Oct 31, 2025
SIG (Susquehanna) logo
SIG (Susquehanna)
Medium
Software Engineer

Implement 3x3 matrix transforms and rotation

Implement 3x3 matrix transforms and rotation For a 3x3 matrix, write Python code to: (a) transpose it in-place; (b) swap any two rows and any two colu...

Coding & Algorithms
17
0
129 people solved
Aug 8, 2025
OpenAI logo
OpenAI
Medium
Software Engineer Locked

Implement Social Follow Recommendations

This question evaluates graph data structure design and traversal, set-based aggregation and ranking logic, and the ability to justify data structure ...

Coding & Algorithms
6
0
48 people solved
May 9, 2026
Plaid logo
Plaid
Easy
Software Engineer

Resolve routing-number to bank mapping

You are given bank-routing data coming from one or more JSON sources. Each source provides a list of records like: `json { "routing": "026009593", "ba...

Coding & Algorithms
25
0
279 people solved
Feb 4, 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