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
Uber logo
Uber
Medium
Software Engineer Locked

Design and Implement an LRU Cache

This question evaluates a candidate's ability to design and implement an LRU cache data structure with O(1) time complexity for both reads and writes....

Coding & Algorithms
0
0
9 people solved
Jun 8, 2026
Amazon logo
Amazon
Hard
Software EngineerSenior+

Return the Vertical Traversal of a Binary Tree

Return the Vertical Traversal of a Binary Tree Problem Implement verticalTraversal(nodeValues, left, right, root) -> columns. Node root is at row 0, c...

Coding & Algorithms
0
0
10 people solved
Jan 1, 2026
Uber logo
Uber
Hard
Software Engineer Locked

Solve Wonderful Strings and Grid Queries

This question evaluates algorithm design and data-structure competencies through two problems: a parity-constrained minimum-cost string transformation...

Coding & Algorithms
3
0
26 people solved
May 13, 2026
Google logo
Google
Medium
Software Engineer

Troubleshoot CPU, latency, and DNS issues

A) A Linux server’s CPU usage suddenly spikes. What immediate checks and commands would you run (e.g., top/htop, pidstat, perf, iostat), how would you...

Coding & Algorithms
6
0
104 people solved
Sep 6, 2025
CloudKitchens logo
CloudKitchens
Medium
Software Engineer

Design receipt system with combo discounts

Question You are building a point-of-sale ordering UI for a food-ordering workflow. You are given class stubs and a callback you must wire up: - Item(...

Coding & Algorithms
12
0
157 people solved
Sep 6, 2025
Snowflake logo
Snowflake
Medium
Software Engineer

Implement crawler and bracket validator

Implement two tasks: ( 1) Write a function crawl(start_urls, fetch, max_depth, domain_filter) that visits pages starting from the given seed URLs usin...

Coding & Algorithms
11
0
134 people solved
Sep 6, 2025
Sigmacomputing logo
Sigmacomputing
Medium
Software Engineer

Evaluate a Boolean Formula AST

Evaluate a Boolean Formula AST Evaluate a formula represented as a JSON-compatible abstract syntax tree. A formula can contain Boolean literals, integ...

Coding & Algorithms
2
0
14 people solved
May 12, 2026
Anthropic logo
Anthropic
Hard
Software Engineer Locked

Implement a hierarchical file store

This question evaluates proficiency in modeling hierarchical file systems, path parsing and manipulation, managing mutable file contents, and analyzin...

Coding & Algorithms
4
0
20 people solved
May 12, 2026
Google logo
Google
Medium
Software Engineer

Find Players with Uniquely Determined Rankings

Find Players with Uniquely Determined Rankings Problem There are n players numbered 0 through n - 1. Each result (winner, loser) states that the winne...

Coding & Algorithms
1
0
10 people solved
Apr 19, 2026
Shopify logo
Shopify
Easy
Data Scientist

Infer and justify non-trivial sequence patterns

Pattern Recognition: Next Terms and Missing Value Identify the rule governing each sequence or row and compute the missing value(s). Justify each answ...

Coding & Algorithms
15
1
126 people solved
Oct 13, 2025
NVIDIA logo
NVIDIA
Hard
Data Scientist

Implement CUDA-tiled matrix multiplication and explain architecture

CUDA FP32 GEMM Design Task Implement a high-performance CUDA kernel for matrix multiplication C = A · B where: - A is m×k, B is k×n, C is m×n - Data t...

Coding & Algorithms
14
0
104 people solved
Oct 13, 2025
Bytedance logo
Bytedance
Easy
Software Engineer

Return the Most Frequent Integer with a Stable Tie-Breaker

Return the Most Frequent Integer with a Stable Tie-Breaker Given a nonempty integer array, return the value that appears most often. If several values...

Coding & Algorithms
1
0
15 people solved
Apr 17, 2026
Zoox logo
Zoox
Medium
Software Engineer Locked

Lane-Change Safety and Longitudinal Motion Simulation

This question tests practical application of kinematics, feedback control, and object-oriented design in a real-time simulation context. It evaluates ...

Coding & Algorithms
0
0
13 people solved
Jun 5, 2026
Qualcomm logo
Qualcomm
Medium
Software Engineer

Compute the Diameter of an Undirected Tree

Compute the Diameter of an Undirected Tree You are given an undirected tree with nodes numbered from 0 through n - 1. The diameter is the number of ed...

Coding & Algorithms
2
0
18 people solved
Apr 16, 2026
Google logo
Google
Hard
Software EngineerSenior+

Convert Valid Snake Case to Lower Camel Case

Convert Valid Snake Case to Lower Camel Case Given a valid snake-case identifier, convert it to lower camel case. The input consists of one or more lo...

Coding & Algorithms
3
2
18 people solved
Apr 16, 2026
Grammarly logo
Grammarly
Easy
Software Engineer

Recover a Rooted Tree from Depth-Annotated Preorder

Recover a Rooted Tree from Depth-Annotated Preorder A rooted, ordered tree was serialized by preorder traversal. Before each node value, the serialize...

Coding & Algorithms
2
0
17 people solved
Jul 6, 2026
Netflix logo
Netflix
Medium
Software Engineer

Implement ordering and undo executor

The interview included two coding tasks: 1. Dependency ordering: Given a set of tasks and their dependency relationships, return a valid execution ord...

Coding & Algorithms
5
0
45 people solved
Apr 15, 2026
LinkedIn logo
LinkedIn
Medium
Software Engineer

Group words that map to same phone digits

Problem On a classic phone keypad (T9), letters map to digits: - 2: ABC, 3: DEF, 4: GHI, 5: JKL, - 6: MNO, 7: PQRS, 8: TUV, 9: WXYZ Given a list of lo...

Coding & Algorithms
8
0
136 people solved
Oct 20, 2025
Airtable logo
Airtable
Medium
Software Engineer

Implement spreadsheet undo/redo operations

Problem Design a data structure that simulates Undo/Redo for a simplified spreadsheet editor. A user performs a sequence of operations on cells. Each ...

Coding & Algorithms
53
0
434 people solved
Nov 4, 2025
Hudson River Trading logo
Hudson River Trading
Medium
Software Engineer

Test easy–medium array/string tasks

For typical easy–medium array and string problems, list the most important edge cases you would test (e.g., empty input, single element, duplicates, a...

Coding & Algorithms
26
0
221 people solved
Sep 6, 2025

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