Coding & Algorithms Interview Questions

Practice 3,469 real coding and algorithms interview questions reported from interviews at Meta, Amazon, Google, Uber and Microsoft. The mix follows what these loops actually ask: arrays and strings, hash maps, two pointers and sliding windows, binary search, linked lists, trees and graphs, BFS and DFS, recursion and backtracking, dynamic programming, heaps and priority queues, and the occasional design-a-data-structure round. Roughly four in five are rated medium, which is where most technical screens sit; 477 are hard and cluster in onsite loops. 3,033 of them open in a console where you can run your solution against the test cases in Python, Java, C++ or JavaScript. 2,712 come from Software Engineer interviews, with the rest from Machine Learning Engineer, Data Scientist and Data Engineer loops, and 404 were set as take-home projects rather than live sessions.

3.5k Questions 368 Companies08.11.2026
Showing 20 results
Role
Meta logo
Meta
Medium
Software EngineerSenior+ Locked

Solve string transform and min-move sorting

This two-part problem evaluates string manipulation and algorithmic problem-solving competencies, specifically rule-based text transformation and comp...

Coding & Algorithms
6
0
99 people solved
Jan 22, 2026
Google logo
Google
Medium
Software Engineer Locked

Solve matrix groups and recipe inventory

This pair of problems evaluates block-wise grid processing and aggregation for minimum-value selection alongside dependency-resolution and resource-al...

Coding & Algorithms
25
0
216 people solved
Jan 22, 2026
Boeing logo
Boeing
Easy
Software Engineer Locked

Compute unique-substring length and first unique index

This question evaluates proficiency in string processing and character-frequency reasoning by combining tasks that measure longest distinct-character ...

Coding & Algorithms
1
0
23 people solved
Jan 22, 2026
TikTok logo
TikTok
Hard
Software Engineer Locked

Find k-th smallest subarray sum

This question evaluates algorithmic problem-solving skills in array processing, specifically understanding of subarray sum properties, selection and r...

Coding & Algorithms
7
0
56 people solved
Jan 22, 2026
Uber logo
Uber
Medium
Software Engineer Locked

Bracket substrings matching any pattern

This question evaluates string manipulation and pattern-matching competency, including substring search, prioritization rules for leftmost and longest...

Coding & Algorithms
8
0
77 people solved
Jan 22, 2026
Apple logo
Apple
Medium
Software Engineer Locked

Solve linked list, grid BFS, and median queries

This multi-part question evaluates proficiency in in-place linked list manipulation, reasoning about shortest connections between connected components...

Coding & Algorithms
26
0
315 people solved
Jan 22, 2026
Salesforce logo
Salesforce
Hard
Software Engineer Locked

Solve sliding window, heap, DP, in-place tasks

This set evaluates proficiency with core algorithmic patterns—sliding-window techniques, heap-based top-k selection, dynamic programming for unbounded...

Coding & Algorithms
29
0
213 people solved
Jan 22, 2026
Applied logo
Applied
Medium
Software Engineer Locked

Merge collinear overlapping 2D segments

This question evaluates computational geometry skills, numerical robustness, and algorithmic implementation for merging collinear, overlapping 2D segm...

Coding & Algorithms
1
0
33 people solved
Jan 22, 2026
Applied logo
Applied
Medium
Software Engineer Locked

Scale Game of Life to huge matrices

This question evaluates a candidate's ability to design space-efficient, I/O-aware algorithms and streaming or external-memory techniques for processi...

Coding & Algorithms
3
0
39 people solved
Jan 22, 2026
Applied logo
Applied
Medium
Software Engineer Locked

Validate JSON against a protobuf-like schema

This question evaluates schema validation and data-typing skills, including understanding of JSON primitive types, recursive message structures, and c...

Coding & Algorithms
1
0
16 people solved
Jan 22, 2026
Databricks logo
Databricks
Hard
Software EngineerNew Grad Locked

Evaluate ACL rules for IP and CIDR

This question evaluates a candidate's competency in IP address and CIDR arithmetic, bitwise reasoning, and algorithm design within the Coding & Algori...

Coding & Algorithms
9
0
62 people solved
Jan 22, 2026
Microsoft logo
Microsoft
Hard
Software Engineer Locked

Return a topological ordering of a graph

This question evaluates understanding of graph algorithms—particularly topological sorting and cycle detection—and competency in ordering dependencies...

Coding & Algorithms
4
0
73 people solved
Jan 22, 2026
Microsoft logo
Microsoft
Hard
Software Engineer Locked

Group GPUs by node and partition by links

This question evaluates understanding of graph algorithms and combinatorial optimization, specifically skills in graph traversal, grouping by node att...

Coding & Algorithms
12
0
87 people solved
Jan 22, 2026
Netflix logo
Netflix
Medium
Software Engineer Locked

Design playlist with add/remove/shuffle

This question evaluates data structure design and algorithmic complexity skills, focusing on managing dynamic sets, uniform random selection, and aver...

Coding & Algorithms
31
0
221 people solved
Jan 22, 2026
Atlassian logo
Atlassian
Medium
Software Engineer Locked

Assign tennis bookings to minimum courts

This question evaluates understanding of interval scheduling and temporal resource allocation, testing algorithm design, complexity analysis, and appr...

Coding & Algorithms
11
0
89 people solved
Jan 22, 2026
Disney logo
Disney
Medium
Software Engineer Locked

Implement an LRU cache

This question evaluates understanding of data structures and algorithmic optimization for constant-time cache operations, with emphasis on cache evict...

Coding & Algorithms
6
0
71 people solved
Jan 22, 2026
Disney logo
Disney
Medium
Software Engineer Locked

Filter ads by a single rule

This question evaluates understanding of rule-based filtering for a single-rule ad filter, including set containment for locations, numeric range chec...

Coding & Algorithms
15
0
130 people solved
Jan 22, 2026
TikTok logo
TikTok
Medium
Software Engineer Locked

Find longest common subsequence length

This question evaluates understanding of dynamic programming and sequence comparison algorithms by asking for the length of the longest common subsequ...

Coding & Algorithms
4
0
39 people solved
Jan 22, 2026
Coinbase logo
Coinbase
Hard
Software Engineer Locked

Implement banking, knapsack, and pagination tasks

This multi-part question evaluates stateful system design, ordered event processing and scheduling semantics for an in-memory banking command processo...

Coding & Algorithms
25
0
294 people solved
Jan 22, 2026
Dropbox logo
Dropbox
Medium
Software Engineer Locked

Build a hit/miss word guessing game

This question evaluates implementation skills in managing stateful systems and data structures for pattern matching, as well as algorithmic and advers...

Coding & Algorithms
8
0
161 people solved
Jan 22, 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