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
Snowflake logo
Snowflake
Easy
Software Engineer Locked

Schedule prerequisite classes with retakes

This question evaluates competency in graph algorithms, dependency resolution, stateful scheduling, and robust error handling within the Coding & Algo...

Coding & Algorithms
14
0
118 people solved
Mar 1, 2026
Bloomberg logo
Bloomberg
Hard
Software Engineer Locked

Find tree root and bucket numbers

This two-part question evaluates understanding of tree data representations and interval bucketing, testing competencies in identifying a tree root fr...

Coding & Algorithms
8
0
76 people solved
Mar 1, 2026
Uber logo
Uber
Medium
Software Engineer

Find minimum activations to absorb all balls

You are given n balls on a 2D plane, where ball i is at coordinate \((x_i, y_i)\). You are also given a distance threshold d. Two balls are considered...

Coding & Algorithms
20
0
257 people solved
Mar 1, 2026
Google logo
Google
Easy
Software Engineer

Compute minimum rooms for time intervals

You are given a list of meeting time intervals, where each interval is represented as [start, end) (start time inclusive, end time exclusive) and star...

Coding & Algorithms
22
0
161 people solved
Mar 1, 2026
Microsoft logo
Microsoft
Medium
Software Engineer Locked

Reconstruct DNA from tagged fragments

This question evaluates understanding of sequence reconstruction, graph modeling, and traversal/orientation constraints, focusing on ordering labeled ...

Coding & Algorithms
7
0
128 people solved
Mar 1, 2026
Uber logo
Uber
Medium
Software Engineer Locked

Group strings that are anagrams

This question evaluates string-processing and data-structuring competency, focusing on identifying and grouping anagrams through comparison of unorder...

Coding & Algorithms
14
0
203 people solved
Mar 1, 2026
Samsung logo
Samsung
Medium
Machine Learning Engineer

Maximize sum of non-adjacent values

Problem You are given an integer array nums representing the amount of money available at each house along a street. If you take money from house i, y...

Coding & Algorithms
4
0
41 people solved
Mar 1, 2026
IBM logo
IBM
Medium
Software Engineer Locked

Compute minimum rooms for meeting schedule

This question evaluates a candidate's competency in interval-based scheduling and resource allocation, assessing understanding of overlapping time int...

Coding & Algorithms
4
0
64 people solved
Mar 1, 2026
MathWorks logo
MathWorks
Easy
Software Engineer

Minimize shortest path by adding weight-1 edges

You are given a weighted directed graph with nodes labeled 1..n. The existing edges are described by three arrays of equal length m: - from[i]: start ...

Coding & Algorithms
3
0
52 people solved
Mar 1, 2026
Two Sigma logo
Two Sigma
Medium
Data Scientist

Evaluate piecewise linear function at x

You are given a polyline defined by n 2D points \((x_i, y_i)\). Connecting consecutive points with straight line segments forms a piecewise linear fun...

Coding & Algorithms
12
0
106 people solved
Mar 1, 2026
xAI logo
xAI
Medium
Software Engineer

Compute dasher pay from order events

Dasher naive pay (active-time with overlapping orders) You are given a list of events describing when a delivery driver ("Dasher") accepts and fulfill...

Coding & Algorithms
16
0
144 people solved
Mar 1, 2026
Anthropic logo
Anthropic
Medium
Software Engineer Locked

Implement crawler and file deduplication

This question evaluates competencies in concurrent programming, web crawling and graph traversal, thread safety, rate limiting, I/O-efficient file ded...

Coding & Algorithms
11
0
97 people solved
Feb 28, 2026
Nooks logo
Nooks
Medium
Software Engineer

Implement a BFS web crawler

A web crawler starts from a URL and explores reachable pages level by level. You are given: - start_url: string - An interface fetch_links(url: string...

Coding & Algorithms
7
0
76 people solved
Feb 28, 2026
Meta logo
Meta
Hard
Software Engineer

Check and infer custom alphabet

You are working with an unknown language that uses a custom alphabetical order, such as ['a', 'd', 'c', 'b', ...]. Implement the following: 1. Check s...

Coding & Algorithms
4
1
67 people solved
Feb 28, 2026
Patreon logo
Patreon
Easy
Software Engineer

Design org chart lookup with preprocessing

You are given an organization chart represented as a list of pairs [managerName, directReportName]. Names are unique strings. The data may form a fore...

Coding & Algorithms
3
0
33 people solved
Feb 28, 2026
Robinhood logo
Robinhood
Hard
Data Engineer

Aggregate user logs into 30-minute sessions

You are given a CSV file with columns: user_id | log_datetime | topic Example input rows (already in time order for the same user): - 001 | 2025-03-01...

Coding & Algorithms
5
0
59 people solved
Feb 28, 2026
Uber logo
Uber
Medium
Data ScientistNew Grad Locked

Implement FizzBuzz

This question evaluates a candidate's ability to implement basic control flow, use modulo operations, iterate over sequences, and reason about time an...

Coding & Algorithms
4
0
51 people solved
Feb 27, 2026
SoFi logo
SoFi
Easy
Software Engineer

Find Smallest Common Row Value

You are given a 2D integer matrix where each row is sorted in strictly increasing order. Return the smallest integer that appears in every row. If no ...

Coding & Algorithms
3
0
55 people solved
Feb 27, 2026
Trexquant logo
Trexquant
Medium
Software Engineer

Streaming Median Tracker

Streaming Median Tracker Design a data structure that ingests integers one at a time from a stream and can report the median of every integer inserted...

Coding & Algorithms
0
0
5 people solved
Feb 26, 2026
Liftoff logo
Liftoff
Medium
Software Engineer

Find degrees of connection in a LinkedIn graph

You are given an undirected graph representing professional connections: - n people labeled 0..n-1 - a list of undirected edges connections, where (a,...

Coding & Algorithms
3
0
38 people solved
Feb 26, 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