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
Amazon logo
Amazon
Hard
Software EngineerSenior+

Evaluate IP Access Rules

You are given a list of IPv4 access-control rules. Each rule consists of: - an action: allow or deny - a CIDR block such as 192.168.0.0/16 You are als...

Coding & Algorithms
15
0
203 people solved
Feb 17, 2026
Meta logo
Meta
Hard
Software Engineer

Remove minimum invalid mixed brackets

Given a string s containing letters and bracket characters from the set (), [], {}, remove the minimum number of bracket characters so that the result...

Coding & Algorithms
7
0
66 people solved
Feb 17, 2026
Meta logo
Meta
Hard
Software Engineer

Connect next pointers for each tree level

You are given the root of a binary tree where each node has fields left, right, and next (initially null). For every node, set its next pointer to the...

Coding & Algorithms
2
1
27 people solved
Feb 17, 2026
Sunrise logo
Sunrise
Easy
Software Engineer

Solve common data-structure and puzzle problems

Solve common data-structure and puzzle problems Solve the following independent problems (language of your choice; assume typical 32/64-bit constraint...

Coding & Algorithms
2
0
38 people solved
Jul 21, 2025
LinkedIn logo
LinkedIn
Medium
Software EngineerSenior+

Solve Cache, Window, and Heap Problems

You may be asked to solve multiple algorithmic problems in coding rounds: 1. Frequency-based cache: Implement a cache with get(key) and put(key, value...

Coding & Algorithms
0
0
14 people solved
Feb 16, 2026
Bytedance logo
Bytedance
Medium
Software Engineer

Count Similar Photo Groups

You are given n photos labeled 0 to n - 1 and an n x n binary matrix isSimilar. - isSimilar[i][j] = 1 means photo i and photo j are directly similar. ...

Coding & Algorithms
2
0
21 people solved
Feb 15, 2026
Microsoft logo
Microsoft
Medium
Software Engineer

Implement greedy decoding and beam search

You are given access to an auto-regressive language model that can score the next token based on a prefix. Assume: - next_logprobs(prefix_tokens) -> M...

Coding & Algorithms
8
0
134 people solved
Feb 15, 2026
Nordstrom logo
Nordstrom
Medium
Software Engineer

Optimize algorithms and validate inputs

Optimize algorithms and validate inputs For a typical medium-difficulty coding task, walk through your approach: enumerate edge cases, justify your in...

Coding & Algorithms
7
0
74 people solved
Jul 17, 2025
Coreweave logo
Coreweave
Medium
Site Reliability Engineer Locked

Query Machines and Mark Them Offline

This question evaluates competency in interacting with RESTful HTTP APIs, JSON parsing and filtering, automation of operational workflows, resilient e...

Coding & Algorithms
9
0
118 people solved
Feb 13, 2026
OpenAI logo
OpenAI
Easy
Software Engineer Locked

Simulate a Turn-Based Two-Player Game

This question evaluates API design, state management, move validation, board representation, and correctness guarantees for a turn-based game simulato...

Coding & Algorithms
11
0
78 people solved
Feb 13, 2026
Turo logo
Turo
Medium
Software Engineer

Check if a word exists in a grid

Given an m×n grid of characters and a string word, determine whether the word can be formed by sequentially adjacent cells (adjacent means horizontall...

Coding & Algorithms
4
0
57 people solved
Feb 12, 2026
Capital One logo
Capital One
Medium
Software Engineer Locked

Remove nodes with a given value

This question evaluates proficiency in singly linked list manipulation, specifically pointer handling and in-place node removal, and falls under the C...

Coding & Algorithms
18
0
176 people solved
Feb 12, 2026
Meta logo
Meta
Easy
Machine Learning Engineer Locked

Solve four OA string/array/matrix/graph tasks

This multi-part prompt evaluates proficiency in core programming competencies: string parsing and character classification, simulation/greedy processi...

Coding & Algorithms
10
0
77 people solved
Feb 12, 2026
Supio logo
Supio
Easy
Software Engineer

Compute max planes shot and session count

Problem 1: Max planes you can shoot before any lands You are given two equal-length arrays: - altitude[i]: the initial altitude of plane i (positive i...

Coding & Algorithms
2
0
38 people solved
Feb 12, 2026
Meta logo
Meta
Medium
Machine Learning Engineer Locked

Solve frequency and tree-completeness problems

These two problems evaluate competency in frequency counting and selection algorithms for identifying top-k elements and in binary tree structure anal...

Coding & Algorithms
4
0
58 people solved
Feb 12, 2026
Jump Trading logo
Jump Trading
Medium
Software Engineer Locked

Identify read-only files from permission records

This question evaluates proficiency in parsing and filtering structured data by interpreting Unix-like permission strings and extracting filenames bas...

Coding & Algorithms
5
0
68 people solved
Feb 12, 2026
Ziprecruiter logo
Ziprecruiter
Medium
Software Engineer Locked

Implement an in-memory storage with TTL and scans

This question evaluates implementation of an in-memory two-level key->field->value store with TTL semantics, lexicographic scans and prefix filtering,...

Coding & Algorithms
3
0
36 people solved
Feb 12, 2026
Uber logo
Uber
Medium
Software Engineer

Solve 12 coding interview problems

Below are multiple independent coding problems. --- Problem 1: Reduce an integer to 0 with \(\pm 2^i\) You are given a positive integer \(n\). In one ...

Coding & Algorithms
352
0
3689 people solved
Feb 12, 2026
Citadel logo
Citadel
Medium
Software Engineer

Compute BBO and NBBO from order data

You are given a list data of order records. Each record is a 4-tuple: ` (exchange_id, price, quantity, order_type) ` - exchange_id: string/int identif...

Coding & Algorithms
20
0
284 people solved
Feb 12, 2026
Millennium logo
Millennium
Medium
Software Engineer Locked

Design a data structure to store anagrams

This question evaluates proficiency in data structures and algorithms for string grouping and lookup, testing skills in string manipulation, canonical...

Coding & Algorithms
5
0
61 people solved
Feb 12, 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